Commit 07001f78 authored by unknown's avatar unknown

- Code cleanup: replaced C++-style comments with the proper syntax for

   .c files (the IBM Visual Age C compiler aborts with a syntax error
   on these)


libmysql/dll.c:
   - replaced C++-style comment with the proper syntax for .c files
     (the IBM Visual Age C compiler aborts with a syntax error on these)
libmysql/libmysql.c:
   - replaced C++-style comment with the proper syntax for .c files
     (the IBM Visual Age C compiler aborts with a syntax error on these)
mysys/my_getopt.c:
   - replaced C++-style comment with the proper syntax for .c files
     (the IBM Visual Age C compiler aborts with a syntax error on these)
sql/net_serv.cc:
   - replaced C++-style comment with the proper syntax for .c files
     (the IBM Visual Age C compiler aborts with a syntax error on these)
strings/ctype-bin.c:
   - replaced C++-style comment with the proper syntax for .c files
     (the IBM Visual Age C compiler aborts with a syntax error on these)
tests/client_test.c:
   - replaced C++-style comment with the proper syntax for .c files
     (the IBM Visual Age C compiler aborts with a syntax error on these)
parent 51f7838a
...@@ -123,7 +123,7 @@ extern "C" unsigned long _System DllMain(unsigned long modhandle, ...@@ -123,7 +123,7 @@ extern "C" unsigned long _System DllMain(unsigned long modhandle,
unsigned long flag) unsigned long flag)
{ {
if (flag == 0) { if (flag == 0) {
tzset(); // Set tzname tzset(); /* Set tzname */
time_t currentTime = time(NULL); time_t currentTime = time(NULL);
struct tm *ts = localtime(&currentTime); struct tm *ts = localtime(&currentTime);
if (ts->tm_isdst > 0) if (ts->tm_isdst > 0)
......
...@@ -629,7 +629,7 @@ my_bool STDCALL mysql_change_user(MYSQL *mysql, const char *user, ...@@ -629,7 +629,7 @@ my_bool STDCALL mysql_change_user(MYSQL *mysql, const char *user,
} }
} }
else else
*end++= '\0'; // empty password *end++= '\0'; /* empty password */
/* Add database if needed */ /* Add database if needed */
end= strmov(end, db ? db : "") + 1; end= strmov(end, db ? db : "") + 1;
......
...@@ -461,7 +461,7 @@ static char *check_struct_option(char *cur_arg, char *key_name) ...@@ -461,7 +461,7 @@ static char *check_struct_option(char *cur_arg, char *key_name)
{ {
char *ptr, *end; char *ptr, *end;
ptr= strcend(cur_arg + 1, '.'); // Skip the first character ptr= strcend(cur_arg + 1, '.'); /* Skip the first character */
end= strcend(cur_arg, '='); end= strcend(cur_arg, '=');
/* /*
......
...@@ -460,7 +460,7 @@ net_real_write(NET *net,const char *packet,ulong len) ...@@ -460,7 +460,7 @@ net_real_write(NET *net,const char *packet,ulong len)
#ifdef MYSQL_SERVER #ifdef MYSQL_SERVER
net->last_errno= ER_OUT_OF_RESOURCES; net->last_errno= ER_OUT_OF_RESOURCES;
net->error= 2; net->error= 2;
//TODO is it needed to set this variable if we have no socket /* TODO is it needed to set this variable if we have no socket */
net->report_error= 1; net->report_error= 1;
#endif #endif
net->reading_or_writing= 0; net->reading_or_writing= 0;
...@@ -889,7 +889,7 @@ my_net_read(NET *net) ...@@ -889,7 +889,7 @@ my_net_read(NET *net)
if (net->remain_in_buf) if (net->remain_in_buf)
{ {
buf_length= net->buf_length; // Data left in old packet buf_length= net->buf_length; /* Data left in old packet */
first_packet_offset= start_of_packet= (net->buf_length - first_packet_offset= start_of_packet= (net->buf_length -
net->remain_in_buf); net->remain_in_buf);
/* Restore the character that was overwritten by the end 0 */ /* Restore the character that was overwritten by the end 0 */
......
...@@ -272,7 +272,7 @@ int my_instr_bin(CHARSET_INFO *cs __attribute__((unused)), ...@@ -272,7 +272,7 @@ int my_instr_bin(CHARSET_INFO *cs __attribute__((unused)),
if (s_length <= b_length) if (s_length <= b_length)
{ {
if (!s_length) if (!s_length)
return 0; // Empty string is always found return 0; /* Empty string is always found */
str= (const uchar*) big; str= (const uchar*) big;
search= (const uchar*) small; search= (const uchar*) small;
......
...@@ -6841,7 +6841,7 @@ static void test_logs() ...@@ -6841,7 +6841,7 @@ static void test_logs()
fprintf(stdout, "\n name : %s(%ld)", data, length); fprintf(stdout, "\n name : %s(%ld)", data, length);
myassert(id == 9876); myassert(id == 9876);
myassert(length == 19);//Due to VARCHAR(20) myassert(length == 19); /* Due to VARCHAR(20) */
myassert(strcmp(data,"MySQL - Open Source")==0); myassert(strcmp(data,"MySQL - Open Source")==0);
rc = mysql_fetch(stmt); rc = mysql_fetch(stmt);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment