MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:Petr Chardin Date:November 30 2006 12:45pm
Subject:bk commit into 5.1 tree (petr:1.2382) BUG#19044
View as plain text  
Below is the list of changes that have just been committed into a local
5.1 repository of cps. When cps 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, 2006-11-30 15:44:51+03:00, petr@stripped +1 -0
  Fix Bug #19044 IM aborts on exit
  
  On windows IM aborted on assert once one
  stoppped it. The reason is that we didn't
  close the sockets on windows and therefore,
  the listener thread wasn't able to finish.
  This happened because we used close() call
  for it. While on windows one should use
  closesocket().
  On other platfroms we have appropriate defines
  for closesocket(), so this is the function which
  should be used.

  server-tools/instance-manager/listener.cc@stripped, 2006-11-30 15:44:47+03:00, petr@stripped +5 -5
    close -> closesocket

# This is a BitKeeper patch.  What follows are the unified diffs for the
# set of deltas contained in the patch.  The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User:	petr
# Host:	outpost.site
# Root:	/home/cps/mysql/trees/mysql-5.1-runtime

--- 1.37/server-tools/instance-manager/listener.cc	2006-11-21 17:47:11 +03:00
+++ 1.38/server-tools/instance-manager/listener.cc	2006-11-30 15:44:47 +03:00
@@ -154,7 +154,7 @@
           else
           {
             shutdown(client_fd, SHUT_RDWR);
-            close(client_fd);
+            closesocket(client_fd);
           }
         }
       }
@@ -166,7 +166,7 @@
   log_info("Listener: shutdown requested, exiting...");
 
   for (i= 0; i < num_sockets; i++)
-    close(sockets[i]);
+    closesocket(sockets[i]);
 
 #ifndef __WIN__
   unlink(unix_socket_address.sun_path);
@@ -180,7 +180,7 @@
 err:
   // we have to close the ip sockets in case of error
   for (i= 0; i < num_sockets; i++)
-    close(sockets[i]);
+    closesocket(sockets[i]);
 
   thread_registry->unregister_thread(&thread_info);
   thread_registry->request_shutdown();
@@ -228,7 +228,7 @@
   {
     log_error("Listener: bind(ip socket) failed: %s.",
               (const char *) strerror(errno));
-    close(ip_socket);
+    closesocket(ip_socket);
     return -1;
   }
 
@@ -236,7 +236,7 @@
   {
     log_error("Listener: listen(ip socket) failed: %s.",
               (const char *) strerror(errno));
-    close(ip_socket);
+    closesocket(ip_socket);
     return -1;
   }
 
Thread
bk commit into 5.1 tree (petr:1.2382) BUG#19044Petr Chardin30 Nov