List:Commits« Previous MessageNext Message »
From:Kevin Lewis Date:May 30 2008 3:29pm
Subject:RE: commit into mysql-6.0-falcon:mysql-6.0-falcon branch (olav:2683) Bug#36703
View as plain text  
Olav,

#include "Engine.h" is rarely ever included into a '.h' file.  It is always included as
the first include file within falcon '.cpp' files.  I think we should continue with this
basic plan.  Every '.cpp' file that includes 'encodedDataStream.h' also includes
'engine.h' except ha_falcon.cpp.  But engine.h should not be included in this file.  That
is how we avoid the name conflicts with the server that Jim mentioned last week.

I think that is the reason that unsigned long is used throughout encodedDataStream.h
instead of UCHAR.  It is used on 8 different lines.  

In think it would be better to do the following instead of including the entire engine.

#ifndef UCHAR
typedef unsigned char		UCHAR;
#endif

And then change all occurances of unsigned char to UCHAR in encodedDataStream.h to match
the way they are defined in encodedDataStream.cpp.  While you are at it, please change

EncodedDataStream::EncodedDataStream(const unsigned char *data, uint length)

in encodedDataStream.cpp also.

EncodedDataStream.cpp
EncodedRecord.cpp
ha_falcon.cpp
Record.cpp
StorageConnection.cpp
StorageDatabase.cpp
StorageTable.cpp
TableSpaceManager.cpp



>-----Original Message-----
>From: Hakan Kuecuekyilmaz [mailto:hakan@stripped]
>Sent: Friday, May 30, 2008 6:40 AM
>To: Olav Sandstaa
>Cc: commits@stripped
>Subject: Re: commit into mysql-6.0-falcon:mysql-6.0-falcon branch
>(olav:2683) Bug#36703
>
>On Fr, 2008-05-30 at 10:09 +0000, Olav Sandstaa wrote:
>> #At bzr+ssh://bk-internal.mysql.com/bzrroot/server/mysql-6.0-falcon/
>>
>>  2683 Olav Sandstaa	2008-05-30
>>       A fix for Bug#36703: Unknown symbol EncodedDataStream::decode when
>linking mysqld with Sun Studio
>>
>>       The problem was due to Sun Studio compiler produced a different
>symbol names in the object files for the decode()
>>       method for the implementation of the method and when it was called.
>>       This was triggered due to that the declartion of the method used
>"unsigned char" while the definition of the method used a UCHAR (which is
>typedef unsigned char).
>>
>>       Fixed this problem by using UCHAR in both declaration and
>definition.
>> modified:
>>   storage/falcon/EncodedDataStream.h
>>
>>
>> === modified file 'storage/falcon/EncodedDataStream.h'
>> --- a/storage/falcon/EncodedDataStream.h	2008-04-21 16:27:11 +0000
>> +++ b/storage/falcon/EncodedDataStream.h	2008-05-30 10:09:31 +0000
>> @@ -31,6 +31,7 @@
>>  #endif
>>
>>  #include "BigInt.h"
>> +#include "Engine.h"
>>
>>  #define BYTES_POS(n)   ((n == 0) ? 0 : \
>>  						(n < (1<<7)) ? 1 : \
>> @@ -335,7 +336,7 @@
>>  	void			encode (int type, Value *value);
>>
>>  	static int		init(void);
>> -	static const unsigned char* decode (const unsigned char *ptr, Value
>*value, bool copyFlag);
>> +	static const UCHAR* decode (const UCHAR *ptr, Value *value, bool
>copyFlag);
>>
>>  	inline static const unsigned char* skip (const unsigned char *ptr)
>>  		{
>>
>>
>
>Olav, ok to push
>
>Best regards,
>
>Hakan
>
>--
>Hakan Küçükyılmaz, Senior Software Engineer DBTG/MySQL +49
> 160 98953296
>Sun Microsystems GmbH     Sonnenallee 1, DE-85551 Kirchheim-Heimstetten
>Geschaeftsfuehrer:  Thomas Schroeder, Wolfang Engels, Dr. Roland Boemer
>Vorsitz d. Aufs.rat.: Martin Haering   HRB MUC 161028     49.011, 8.376
>
>
>--
>MySQL Code Commits Mailing List
>For list archives: http://lists.mysql.com/commits
>To unsubscribe:    http://lists.mysql.com/commits?unsub=1

Thread
commit into mysql-6.0-falcon:mysql-6.0-falcon branch (olav:2683) Bug#36703Olav Sandstaa30 May
  • Re: commit into mysql-6.0-falcon:mysql-6.0-falcon branch(olav:2683) Bug#36703Hakan Kuecuekyilmaz30 May
    • RE: commit into mysql-6.0-falcon:mysql-6.0-falcon branch (olav:2683) Bug#36703Kevin Lewis30 May
      • RE: commit into mysql-6.0-falcon:mysql-6.0-falcon branch (olav:2683) Bug#36703Vladislav Vaintroub30 May
        • RE: commit into mysql-6.0-falcon:mysql-6.0-falcon branch (olav:2683) Bug#36703Kevin Lewis30 May