summaryrefslogtreecommitdiff
path: root/server-tools/instance-manager
diff options
context:
space:
mode:
Diffstat (limited to 'server-tools/instance-manager')
-rw-r--r--server-tools/instance-manager/buffer.cc2
-rw-r--r--server-tools/instance-manager/buffer.h2
-rw-r--r--server-tools/instance-manager/command.cc2
-rw-r--r--server-tools/instance-manager/command.h2
-rw-r--r--server-tools/instance-manager/guardian.cc2
-rw-r--r--server-tools/instance-manager/guardian.h2
-rw-r--r--server-tools/instance-manager/instance.cc2
-rw-r--r--server-tools/instance-manager/instance.h2
-rw-r--r--server-tools/instance-manager/instance_map.cc2
-rw-r--r--server-tools/instance-manager/instance_map.h2
-rw-r--r--server-tools/instance-manager/instance_options.cc4
-rw-r--r--server-tools/instance-manager/instance_options.h2
-rw-r--r--server-tools/instance-manager/listener.cc2
-rw-r--r--server-tools/instance-manager/listener.h2
-rw-r--r--server-tools/instance-manager/mysql_connection.cc2
-rw-r--r--server-tools/instance-manager/mysql_connection.h2
-rw-r--r--server-tools/instance-manager/options.cc2
-rw-r--r--server-tools/instance-manager/options.h2
-rw-r--r--server-tools/instance-manager/parse_output.cc1
-rw-r--r--server-tools/instance-manager/protocol.cc14
-rw-r--r--server-tools/instance-manager/thread_registry.cc2
-rw-r--r--server-tools/instance-manager/thread_registry.h2
-rw-r--r--server-tools/instance-manager/user_map.cc2
-rw-r--r--server-tools/instance-manager/user_map.h2
24 files changed, 30 insertions, 31 deletions
diff --git a/server-tools/instance-manager/buffer.cc b/server-tools/instance-manager/buffer.cc
index dd6e6e95704..8039ab24481 100644
--- a/server-tools/instance-manager/buffer.cc
+++ b/server-tools/instance-manager/buffer.cc
@@ -14,7 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_IMPLEMENTATION)
#pragma implementation
#endif
diff --git a/server-tools/instance-manager/buffer.h b/server-tools/instance-manager/buffer.h
index 0c4d1eda102..afc71320ecb 100644
--- a/server-tools/instance-manager/buffer.h
+++ b/server-tools/instance-manager/buffer.h
@@ -19,7 +19,7 @@
#include <my_global.h>
#include <my_sys.h>
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_INTERFACE)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/command.cc b/server-tools/instance-manager/command.cc
index 73dd49ef8b8..f76366d5661 100644
--- a/server-tools/instance-manager/command.cc
+++ b/server-tools/instance-manager/command.cc
@@ -14,7 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_IMPLEMENTATION)
#pragma implementation
#endif
diff --git a/server-tools/instance-manager/command.h b/server-tools/instance-manager/command.h
index 8ae4e33b92f..82ded800e65 100644
--- a/server-tools/instance-manager/command.h
+++ b/server-tools/instance-manager/command.h
@@ -16,7 +16,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_INTERFACE)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/guardian.cc b/server-tools/instance-manager/guardian.cc
index 17f4204185a..a4c0cef41b3 100644
--- a/server-tools/instance-manager/guardian.cc
+++ b/server-tools/instance-manager/guardian.cc
@@ -15,7 +15,7 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_IMPLEMENTATION)
#pragma implementation
#endif
diff --git a/server-tools/instance-manager/guardian.h b/server-tools/instance-manager/guardian.h
index 758c4a3f3bc..16180e72dc9 100644
--- a/server-tools/instance-manager/guardian.h
+++ b/server-tools/instance-manager/guardian.h
@@ -22,7 +22,7 @@
#include <my_sys.h>
#include <my_list.h>
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_INTERFACE)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/instance.cc b/server-tools/instance-manager/instance.cc
index 5e1c3d2ea9f..0c3c1aee5b4 100644
--- a/server-tools/instance-manager/instance.cc
+++ b/server-tools/instance-manager/instance.cc
@@ -14,7 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_IMPLEMENTATION)
#pragma implementation
#endif
diff --git a/server-tools/instance-manager/instance.h b/server-tools/instance-manager/instance.h
index 003cbca8cef..adb66991685 100644
--- a/server-tools/instance-manager/instance.h
+++ b/server-tools/instance-manager/instance.h
@@ -19,7 +19,7 @@
#include <my_global.h>
#include "instance_options.h"
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_INTERFACE)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/instance_map.cc b/server-tools/instance-manager/instance_map.cc
index b3a207ae79f..611eda457f2 100644
--- a/server-tools/instance-manager/instance_map.cc
+++ b/server-tools/instance-manager/instance_map.cc
@@ -14,7 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_IMPLEMENTATION)
#pragma implementation
#endif
diff --git a/server-tools/instance-manager/instance_map.h b/server-tools/instance-manager/instance_map.h
index 47037e0d433..51971db4c2f 100644
--- a/server-tools/instance-manager/instance_map.h
+++ b/server-tools/instance-manager/instance_map.h
@@ -24,7 +24,7 @@
#include <my_sys.h>
#include <hash.h>
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_INTERFACE)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/instance_options.cc b/server-tools/instance-manager/instance_options.cc
index 70950a91015..25609f489af 100644
--- a/server-tools/instance-manager/instance_options.cc
+++ b/server-tools/instance-manager/instance_options.cc
@@ -14,7 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_IMPLEMENTATION)
#pragma implementation
#endif
@@ -469,7 +469,7 @@ int Instance_options::add_option(const char* option)
case SAVE_WHOLE:
*(selected_options->value)= tmp;
return 0;
- defaut:
+ default:
break;
}
}
diff --git a/server-tools/instance-manager/instance_options.h b/server-tools/instance-manager/instance_options.h
index dc62d277a43..dae1c2695d1 100644
--- a/server-tools/instance-manager/instance_options.h
+++ b/server-tools/instance-manager/instance_options.h
@@ -21,7 +21,7 @@
#include "parse.h"
#include "portability.h"
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_INTERFACE)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/listener.cc b/server-tools/instance-manager/listener.cc
index 374946d3b73..a1c1a743c24 100644
--- a/server-tools/instance-manager/listener.cc
+++ b/server-tools/instance-manager/listener.cc
@@ -14,7 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_IMPLEMENTATION)
#pragma implementation
#endif
diff --git a/server-tools/instance-manager/listener.h b/server-tools/instance-manager/listener.h
index 67a090c3aa2..3f5a80f1f53 100644
--- a/server-tools/instance-manager/listener.h
+++ b/server-tools/instance-manager/listener.h
@@ -16,7 +16,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_INTERFACE)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/mysql_connection.cc b/server-tools/instance-manager/mysql_connection.cc
index dfa12f6f6e2..4a32e95450e 100644
--- a/server-tools/instance-manager/mysql_connection.cc
+++ b/server-tools/instance-manager/mysql_connection.cc
@@ -14,7 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_IMPLEMENTATION)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/mysql_connection.h b/server-tools/instance-manager/mysql_connection.h
index e0109ce234f..2ff55d81e57 100644
--- a/server-tools/instance-manager/mysql_connection.h
+++ b/server-tools/instance-manager/mysql_connection.h
@@ -16,7 +16,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_INTERFACE)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/options.cc b/server-tools/instance-manager/options.cc
index 74ccade3a2c..b16fcabae01 100644
--- a/server-tools/instance-manager/options.cc
+++ b/server-tools/instance-manager/options.cc
@@ -14,7 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_IMPLEMENTATION)
#pragma implementation
#endif
diff --git a/server-tools/instance-manager/options.h b/server-tools/instance-manager/options.h
index a5cd049decf..3a60de2bb39 100644
--- a/server-tools/instance-manager/options.h
+++ b/server-tools/instance-manager/options.h
@@ -16,7 +16,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_INTERFACE)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/parse_output.cc b/server-tools/instance-manager/parse_output.cc
index 4ec9a71bfd2..b5af3cb83a7 100644
--- a/server-tools/instance-manager/parse_output.cc
+++ b/server-tools/instance-manager/parse_output.cc
@@ -107,7 +107,6 @@ int parse_output_and_get_value(const char *command, const char *word,
}
}
-pclose:
/* we are not interested in the termination status */
pclose(output);
diff --git a/server-tools/instance-manager/protocol.cc b/server-tools/instance-manager/protocol.cc
index cd1be805b6b..e14449746fd 100644
--- a/server-tools/instance-manager/protocol.cc
+++ b/server-tools/instance-manager/protocol.cc
@@ -74,7 +74,7 @@ int net_send_error(struct st_net *net, uint sql_errno)
MYSQL_ERRMSG_SIZE]; // message
char *pos= buff;
- enum { ERROR_PACKET_CODE= 255 };
+ const int ERROR_PACKET_CODE= 255;
*pos++= ERROR_PACKET_CODE;
int2store(pos, sql_errno);
pos+= 2;
@@ -95,7 +95,7 @@ int net_send_error_323(struct st_net *net, uint sql_errno)
MYSQL_ERRMSG_SIZE]; // message
char *pos= buff;
- enum { ERROR_PACKET_CODE= 255 };
+ const int ERROR_PACKET_CODE= 255;
*pos++= ERROR_PACKET_CODE;
int2store(pos, sql_errno);
pos+= 2;
@@ -148,14 +148,14 @@ int store_to_protocol_packet(Buffer *buf, const char *string, uint *position)
int send_eof(struct st_net *net)
{
- char buff[1 + /* eof packet code */
- 2 + /* warning count */
- 2]; /* server status */
+ uchar buff[1 + /* eof packet code */
+ 2 + /* warning count */
+ 2]; /* server status */
buff[0]=254;
int2store(buff+1, 0);
int2store(buff+3, 0);
- return my_net_write(net, buff, sizeof buff);
+ return my_net_write(net, (char*) buff, sizeof buff);
}
int send_fields(struct st_net *net, LIST *fields)
@@ -195,7 +195,7 @@ int send_fields(struct st_net *net, LIST *fields)
int2store(send_buff.buffer + position, 1); /* charsetnr */
int4store(send_buff.buffer + position + 2,
field->length); /* field length */
- send_buff.buffer[position+6]= FIELD_TYPE_STRING; /* type */
+ send_buff.buffer[position+6]= (uint) FIELD_TYPE_STRING; /* type */
int2store(send_buff.buffer + position + 7, 0); /* flags */
send_buff.buffer[position + 9]= (char) 0; /* decimals */
send_buff.buffer[position + 10]= 0;
diff --git a/server-tools/instance-manager/thread_registry.cc b/server-tools/instance-manager/thread_registry.cc
index a7384c0fa13..fe665f410e5 100644
--- a/server-tools/instance-manager/thread_registry.cc
+++ b/server-tools/instance-manager/thread_registry.cc
@@ -14,7 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_IMPLEMENTATION)
#pragma implementation
#endif
diff --git a/server-tools/instance-manager/thread_registry.h b/server-tools/instance-manager/thread_registry.h
index 28899810f23..a1075e719d6 100644
--- a/server-tools/instance-manager/thread_registry.h
+++ b/server-tools/instance-manager/thread_registry.h
@@ -50,7 +50,7 @@
in manner, similar to ``quit'' signals.
*/
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_INTERFACE)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/user_map.cc b/server-tools/instance-manager/user_map.cc
index 93c4a2ade25..d901d1ca5ec 100644
--- a/server-tools/instance-manager/user_map.cc
+++ b/server-tools/instance-manager/user_map.cc
@@ -14,7 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_IMPLEMENTATION)
#pragma interface
#endif
diff --git a/server-tools/instance-manager/user_map.h b/server-tools/instance-manager/user_map.h
index 4c86edd93d9..a57174a37c3 100644
--- a/server-tools/instance-manager/user_map.h
+++ b/server-tools/instance-manager/user_map.h
@@ -16,7 +16,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
-#ifdef __GNUC__
+#if defined(__GNUC__) && defined(USE_PRAGMA_INTERFACE)
#pragma interface
#endif