summaryrefslogtreecommitdiff
path: root/server-tools
diff options
context:
space:
mode:
authorunknown <hartmut@mysql.com/linux.site>2006-08-05 13:41:22 +0200
committerunknown <hartmut@mysql.com/linux.site>2006-08-05 13:41:22 +0200
commite061ed925f69c12d8ec18fecc9a5603333f77643 (patch)
tree6f2d8f2da88c784172a55f3c87392c014b833d8b /server-tools
parentfaf2e23dc50a99f8074549c735811d94f0385827 (diff)
downloadmariadb-git-e061ed925f69c12d8ec18fecc9a5603333f77643.tar.gz
relying on loop counter variables being local to the loop body if
declared in the 'for' statement is not portable, some compilers still don't implement this ANSI C++ specification (Bug #14995)
Diffstat (limited to 'server-tools')
-rw-r--r--server-tools/instance-manager/listener.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/server-tools/instance-manager/listener.cc b/server-tools/instance-manager/listener.cc
index 67d798a1700..500b25bec03 100644
--- a/server-tools/instance-manager/listener.cc
+++ b/server-tools/instance-manager/listener.cc
@@ -88,7 +88,7 @@ Listener_thread::~Listener_thread()
void Listener_thread::run()
{
- int n= 0;
+ int i, n= 0;
#ifndef __WIN__
/* we use this var to check whether we are running on LinuxThreads */
@@ -117,7 +117,7 @@ void Listener_thread::run()
#endif
/* II. Listen sockets and spawn childs */
- for (int i= 0; i < num_sockets; i++)
+ for (i= 0; i < num_sockets; i++)
n= max(n, sockets[i]);
n++;
@@ -176,7 +176,7 @@ void Listener_thread::run()
log_info("Listener_thread::run(): shutdown requested, exiting...");
- for (int i= 0; i < num_sockets; i++)
+ for (i= 0; i < num_sockets; i++)
close(sockets[i]);
#ifndef __WIN__
@@ -189,7 +189,7 @@ void Listener_thread::run()
err:
// we have to close the ip sockets in case of error
- for (int i= 0; i < num_sockets; i++)
+ for (i= 0; i < num_sockets; i++)
close(sockets[i]);
thread_registry.unregister_thread(&thread_info);