List:Commits« Previous MessageNext Message »
From:kpettersson Date:March 18 2008 12:50pm
Subject:bk commit into 5.0 tree (thek:1.2596) BUG#32059
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of thek.  When thek does a push these changes
will be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html

ChangeSet@stripped, 2008-03-18 13:50:07+01:00, thek@adventure.(none) +2 -0
  Bug#32059 thread_id is a long rather than ulong
  
  thread_id was a long rather than a ulong.  The reason this is an issue is because
  we don't ever reset it back to 1, we seem to rely on the value "rolling over" when
  the type max is reached (4294967295 for a ulong).  We are currently using a signed 
  long which means that when we reach the limit (2147483647) it will roll over to
  -2147483647 instead of 1.
  

  include/mysql.h@stripped, 2008-03-18 13:49:53+01:00, thek@adventure.(none) +1 -1
    * thread_id is an unsigned number.

  mysys/my_thr_init.c@stripped, 2008-03-18 13:49:53+01:00, thek@adventure.(none) +1 -1
    * Change global variable thread_id to unsigned long.

diff -Nrup a/include/mysql.h b/include/mysql.h
--- a/include/mysql.h	2007-11-26 17:09:35 +01:00
+++ b/include/mysql.h	2008-03-18 13:49:53 +01:00
@@ -264,7 +264,7 @@ typedef struct st_mysql
   my_ulonglong affected_rows;
   my_ulonglong insert_id;		/* id if insert on table with NEXTNR */
   my_ulonglong extra_info;		/* Not used */
-  unsigned long thread_id;		/* Id for connection in server */
+  unsigned ulong thread_id;		/* Id for connection in server */
   unsigned long packet_length;
   unsigned int	port;
   unsigned long client_flag,server_capabilities;
diff -Nrup a/mysys/my_thr_init.c b/mysys/my_thr_init.c
--- a/mysys/my_thr_init.c	2007-08-16 16:25:45 +02:00
+++ b/mysys/my_thr_init.c	2008-03-18 13:49:53 +01:00
@@ -223,7 +223,7 @@ void my_thread_global_end(void)
 #endif
 }
 
-static long thread_id=0;
+static ulong thread_id=0;
 
 /*
   Allocate thread specific memory for the thread, used by mysys and dbug
Thread
bk commit into 5.0 tree (thek:1.2596) BUG#32059kpettersson18 Mar