diff options
author | monty@mashka.mysql.fi <> | 2003-01-05 20:18:49 +0200 |
---|---|---|
committer | monty@mashka.mysql.fi <> | 2003-01-05 20:18:49 +0200 |
commit | 9ecf9645ebab531ce5aa29514b6b9457968f9946 (patch) | |
tree | ce42417ba1ab6dac8c367a9ae180ea377956e95a | |
parent | 5e77a27182fe6a2544e3e4b0ad23399c9fb2ca48 (diff) | |
download | mariadb-git-9ecf9645ebab531ce5aa29514b6b9457968f9946.tar.gz |
A lot of portability fixes.
Added rename table for BDB. This fixes a bug in ALTER TABLE with BDB tables.
-rw-r--r-- | BUILD/SETUP.sh | 2 | ||||
-rwxr-xr-x | Build-tools/Do-compile | 53 | ||||
-rw-r--r-- | acinclude.m4 | 2 | ||||
-rw-r--r-- | configure.in | 5 | ||||
-rw-r--r-- | innobase/include/univ.i | 1 | ||||
-rw-r--r-- | innobase/os/os0file.c | 2 | ||||
-rw-r--r-- | innobase/trx/trx0sys.c | 6 | ||||
-rw-r--r-- | innobase/trx/trx0trx.c | 2 | ||||
-rw-r--r-- | innobase/ut/ut0ut.c | 1 | ||||
-rw-r--r-- | myisam/mi_check.c | 2 | ||||
-rw-r--r-- | myisam/mi_test1.c | 2 | ||||
-rw-r--r-- | mysys/my_getopt.c | 4 | ||||
-rw-r--r-- | sql/ha_berkeley.cc | 24 | ||||
-rw-r--r-- | sql/ha_berkeley.h | 1 | ||||
-rw-r--r-- | sql/mini_client.cc | 11 | ||||
-rw-r--r-- | sql/sql_parse.cc | 11 | ||||
-rw-r--r-- | sql/sql_union.cc | 2 | ||||
-rw-r--r-- | sql/table.cc | 2 | ||||
-rw-r--r-- | tools/mysqlmanager.c | 2 |
19 files changed, 99 insertions, 36 deletions
diff --git a/BUILD/SETUP.sh b/BUILD/SETUP.sh index 859150c3954..9a092b84a8f 100644 --- a/BUILD/SETUP.sh +++ b/BUILD/SETUP.sh @@ -48,7 +48,7 @@ fast_cflags="-O3 -fno-omit-frame-pointer" # this is one is for someone who thinks 1% speedup is worth not being # able to backtrace reckless_cflags="-O3 -fomit-frame-pointer " -debug_cflags="-DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC -DSAFE_MUTEX -O1" +debug_cflags="-DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC -DSAFE_MUTEX -O1 -Wuninitialized" base_cxxflags="-felide-constructors -fno-exceptions -fno-rtti" diff --git a/Build-tools/Do-compile b/Build-tools/Do-compile index 52c1951f48f..4351a4f69f4 100755 --- a/Build-tools/Do-compile +++ b/Build-tools/Do-compile @@ -8,7 +8,7 @@ use Getopt::Long; $opt_distribution=$opt_user=$opt_config_env=""; $opt_dbd_options=$opt_perl_options=$opt_config_options=$opt_make_options=$opt_suffix=""; $opt_tmp=$opt_version_suffix=""; -$opt_help=$opt_delete=$opt_debug=$opt_stage=$opt_no_test=$opt_no_perl=$opt_with_low_memory=$opt_fast_benchmark=$opt_static_client=$opt_static_server=$opt_static_perl=$opt_sur=$opt_with_small_disk=$opt_local_perl=$opt_tcpip=$opt_build_thread=$opt_use_old_distribution=$opt_enable_shared=$opt_no_crash_me=$opt_no_strip=$opt_with_debug=0; +$opt_help=$opt_delete=$opt_debug=$opt_stage=$opt_no_test=$opt_no_perl=$opt_with_low_memory=$opt_fast_benchmark=$opt_static_client=$opt_static_server=$opt_static_perl=$opt_sur=$opt_with_small_disk=$opt_local_perl=$opt_tcpip=$opt_build_thread=$opt_use_old_distribution=$opt_enable_shared=$opt_no_crash_me=$opt_no_strip=$opt_with_debug=$opt_no_benchmark=$opt_no_mysqltest=0; $opt_innodb=$opt_bdb=$opt_raid=$opt_libwrap=0; GetOptions( @@ -30,7 +30,9 @@ GetOptions( "no-crash-me", "no-perl", "no-strip", - "no-test|no-mysqltest", + "no-test", + "no-mysqltest", + "no-benchmark", "perl-files=s", "perl-options=s", "raid", @@ -148,6 +150,7 @@ select STDOUT; $|=1; info("Compiling MySQL$opt_version_suffix at $host$opt_suffix, stage: $opt_stage\n"); +log_timestamp(); if (-x "$host/bin/mysqladmin") { @@ -161,6 +164,7 @@ kill_all("mysqlmanager"); if ($opt_stage == 0) { + log_timestamp(); print "$host: Removing old distribution\n" if ($opt_debug); if (!$opt_use_old_distribution) { @@ -209,6 +213,7 @@ safe_cd("$pwd/$host/$ver"); if ($opt_stage <= 1) { # Fix files if this is in another timezone than the build host + log_timestamp(); unlink("config.cache"); unlink("bdb/build_unix/config.cache"); unlink("innobase/config.cache"); @@ -252,6 +257,7 @@ if ($opt_stage <= 1) if ($opt_stage <= 2) { my ($command); + log_timestamp(); unlink($opt_distribution) if ($opt_delete && !$opt_use_old_distribution); $command=$make; $command.= " $opt_make_options" if (defined($opt_make_options) && $opt_make_options ne ""); @@ -264,6 +270,7 @@ if ($opt_stage <= 2) if ($opt_stage <= 3) { my $flags= ""; + log_timestamp(); log_system("rm -fr mysql-3* mysql-4* $pwd/$host/*.tar.gz"); log_system("nm -n sql/mysqld | gzip -9 -v 2>&1 > sql/mysqld.sym.gz | cat"); @@ -292,6 +299,7 @@ if (!defined($tar_file)) # if ($opt_stage <= 4 && !$opt_no_test) { + log_timestamp(); rm_all(<$pwd/$host/test/*>); safe_cd("$pwd/$host/test"); safe_system("gunzip < $tar_file | $tar xf -"); @@ -305,8 +313,9 @@ $ENV{"LD_LIBRARY_PATH"}= "$test_dir/lib:" . $ENV{"LD_LIBRARY_PATH"}; # # Run the test suite # -if ($opt_stage <= 5 && !$opt_no_test) +if ($opt_stage <= 5 && !$opt_no_test && !$opt_no_mysqltest) { + log_timestamp(); system("mkdir $bench_tmpdir") if (! -d $bench_tmpdir); safe_cd("${test_dir}/mysql-test"); check_system("./mysql-test-run --warnings --tmpdir=$bench_tmpdir --master_port=$mysql_tcp_port --slave_port=$slave_port --manager-port=$manager_port --no-manager --sleep=10", "tests were successful"); @@ -315,7 +324,7 @@ if ($opt_stage <= 5 && !$opt_no_test) # # Start the server if we are going to run any of the benchmarks # -if (!$opt_no_test) +if (!$opt_no_test && !$opt_no_benchmark) { my $extra; safe_cd($test_dir); @@ -339,8 +348,10 @@ if (!$opt_no_test) # # Compile and install the required Perl modules # -if ($opt_stage <= 7 && $opt_perl_files && !$opt_no_perl && !$opt_no_test) +if ($opt_stage <= 7 && $opt_perl_files && !$opt_no_perl && !$opt_no_test && + !$opt_no_benchmark) { + log_timestamp(); safe_cd($test_dir); rm_all("perl"); safe_system("mkdir perl"); @@ -376,6 +387,7 @@ if ($opt_stage <= 7 && $opt_perl_files && !$opt_no_perl && !$opt_no_test) # if ($opt_stage <= 8 && !$opt_no_test && !$opt_no_crash_me) { + log_timestamp(); safe_cd("$test_dir/sql-bench"); log_system("rm -f limits/mysql.cfg"); safe_system("perl ./crash-me --force --batch-mode $connect_option"); @@ -384,8 +396,9 @@ if ($opt_stage <= 8 && !$opt_no_test && !$opt_no_crash_me) # # Run sql-bench Benchmarks # -if ($opt_stage <= 9 && !$opt_no_test) +if ($opt_stage <= 9 && !$opt_no_test && !$opt_no_benchmark) { + log_timestamp(); safe_cd("$test_dir/sql-bench"); log_system("rm -f output/*"); $tmp= $opt_fast_benchmark ? "--fast --user root --small-test" : ""; @@ -469,7 +482,13 @@ Do not run the "crash-me" test Do not strip the binaries included in the binary distribution --no-test -Do not run any tests +Do not run any tests. + +--no-benchmark +Do not run the benchmark test (written in perl) + +--no-mysqltest +Do not run the the mysql-test-run test (Same as 'make test') --perl-files=list of files Compile and install the given perl modules. @@ -532,6 +551,7 @@ sub abort my($mail_header_file); print LOG "\n$message\n"; print "$host: $message\n" if ($opt_debug); + print LOG "Aborting\n"; close LOG; if ($opt_user) @@ -547,7 +567,6 @@ sub abort unlink($mail_header_file); unlink("$log.mail"); } - print LOG "Aborting\n"; exit 1; } @@ -689,9 +708,10 @@ sub rm_all sub kill_all { my ($pattern) = @_; - my ($USER,$BSD,$LINUX, $pscmd, $user, $pid); + my ($USER,$BSD,$LINUX, $pscmd, $user, $os, $pid); $user=$ENV{'USER'}; - $BSD = -f '/vmunix' || $ENV{"OS"} eq "SunOS4" || $^O eq 'darwin'; + $os=defined($ENV{'OS'}) ? $ENV{'OS'} : "unknown"; + $BSD = -f '/vmunix' || $os eq "SunOS4" || $^O eq 'darwin'; $LINUX = $^O eq 'linux'; $pscmd = $BSD ? "/bin/ps -auxww" : $LINUX ? "/bin/ps axuw" : "/bin/ps -ef"; @@ -707,7 +727,7 @@ sub kill_all { chop($cand); ($pid_user, $pid) = split(' ', $cand); - next if $pid == $$; + next if $pid eq $$; next process if (! ($cand =~ $pattern) || $pid_user ne $user); print LOG "Killing $_\n"; &killpid($pid); @@ -730,3 +750,14 @@ sub killpid } print LOG "$pid will not die!\n"; } + +# +# return the current date as a string (YYYY-MM-DD HH:MM:SS) +# +sub log_timestamp +{ + my @ta=localtime(time()); + print LOG sprintf("%4d-%02d-%02d %02d:%02d:%02d\n", + $ta[5]+1900, $ta[4]+1, $ta[3], $ta[2], $ta[1], $ta[0]); + +} diff --git a/acinclude.m4 b/acinclude.m4 index 7436b5136a5..cf0233fa38f 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -623,7 +623,7 @@ main() FILE *file=fopen("conftestval", "w"); f = (float) ll; fprintf(file,"%g\n",f); - close(file); + fclose(file); exit (0); }], ac_cv_conv_longlong_to_float=`cat conftestval`, ac_cv_conv_longlong_to_float=0, ifelse([$2], , , ac_cv_conv_longlong_to_float=$2))])dnl if test "$ac_cv_conv_longlong_to_float" = "1" -o "$ac_cv_conv_longlong_to_float" = "yes" diff --git a/configure.in b/configure.in index 9e3a8ffc516..0375cc61235 100644 --- a/configure.in +++ b/configure.in @@ -879,6 +879,7 @@ int main() # MAX_C_OPTIMIZE="-O3" +MAX_CXX_OPTIMIZE="-O3" case $SYSTEM_TYPE in *solaris2.7*) @@ -946,6 +947,8 @@ case $SYSTEM_TYPE in then CFLAGS="$CFLAGS +DD64 -DHAVE_BROKEN_INLINE" CXXFLAGS="$CXXFLAGS +DD64 +O2" + MAX_C_OPTIMIZE="" + MAX_CXX_OPTIMIZE="" fi ;; *rhapsody*) @@ -1404,7 +1407,7 @@ if test "$ac_cv_prog_cxx_g" = "yes" then DEBUG_CXXFLAGS="-g" DEBUG_OPTIMIZE_CXX="-O" - OPTIMIZE_CXXFLAGS="-O3" + OPTIMIZE_CXXFLAGS="$MAX_CXX_OPTIMIZE" else DEBUG_CXXFLAGS="-g" DEBUG_OPTIMIZE_CXX="" diff --git a/innobase/include/univ.i b/innobase/include/univ.i index 43130549eae..bf606efcf64 100644 --- a/innobase/include/univ.i +++ b/innobase/include/univ.i @@ -57,6 +57,7 @@ of the 32-bit x86 assembler in mutex operations. */ Microsoft Visual C++ */ #if !defined(__GNUC__) && !defined(__WIN__) +#undef UNIV_MUST_NOT_INLINE /* Remove compiler warning */ #define UNIV_MUST_NOT_INLINE #endif diff --git a/innobase/os/os0file.c b/innobase/os/os0file.c index 9eae358c7fb..fa5482a8cd1 100644 --- a/innobase/os/os0file.c +++ b/innobase/os/os0file.c @@ -2127,7 +2127,7 @@ os_aio_simulated_handle( ulint offs; ulint lowest_offset; byte* combined_buf; - byte* combined_buf2; + byte* combined_buf2= 0; /* Remove warning */ ibool ret; ulint n; ulint i; diff --git a/innobase/trx/trx0sys.c b/innobase/trx/trx0sys.c index 33c962772e8..0c10040847e 100644 --- a/innobase/trx/trx0sys.c +++ b/innobase/trx/trx0sys.c @@ -472,9 +472,9 @@ trx_sys_update_mysql_binlog_offset( if (0 != ut_memcmp(sys_header + field + TRX_SYS_MYSQL_LOG_NAME, file_name, 1 + ut_strlen(file_name))) { - mlog_write_string(sys_header + field - + TRX_SYS_MYSQL_LOG_NAME, - file_name, 1 + ut_strlen(file_name), mtr); + mlog_write_string((byte*) (sys_header + field + + TRX_SYS_MYSQL_LOG_NAME), + (byte*) file_name, 1 + ut_strlen(file_name), mtr); } if (mach_read_from_4(sys_header + field diff --git a/innobase/trx/trx0trx.c b/innobase/trx/trx0trx.c index f0077f941de..d2219ed019f 100644 --- a/innobase/trx/trx0trx.c +++ b/innobase/trx/trx0trx.c @@ -99,7 +99,7 @@ trx_create( trx->mysql_log_file_name = NULL; trx->mysql_log_offset = 0; - trx->mysql_master_log_file_name = ""; + trx->mysql_master_log_file_name = (char*) ""; trx->mysql_master_log_pos = 0; trx->ignore_duplicates_in_insert = FALSE; diff --git a/innobase/ut/ut0ut.c b/innobase/ut/ut0ut.c index ff5d11d84ed..bb5eb662cd7 100644 --- a/innobase/ut/ut0ut.c +++ b/innobase/ut/ut0ut.c @@ -197,7 +197,6 @@ ut_get_year_month_day( *month = (ulint)cal_tm.wMonth; *day = (ulint)cal_tm.wDay; #else - struct tm cal_tm; struct tm* cal_tm_ptr; time_t tm; diff --git a/myisam/mi_check.c b/myisam/mi_check.c index d1165899bea..540f3c92ad3 100644 --- a/myisam/mi_check.c +++ b/myisam/mi_check.c @@ -3650,7 +3650,7 @@ void update_key_parts(MI_KEYDEF *keyinfo, ulong *rec_per_key_part, } -ha_checksum mi_byte_checksum(const byte *buf, uint length) +static ha_checksum mi_byte_checksum(const byte *buf, uint length) { ha_checksum crc; const byte *end=buf+length; diff --git a/myisam/mi_test1.c b/myisam/mi_test1.c index bcb9cd172ec..8ea97c8e489 100644 --- a/myisam/mi_test1.c +++ b/myisam/mi_test1.c @@ -57,7 +57,7 @@ int main(int argc,char *argv[]) } -int run_test(const char *filename) +static int run_test(const char *filename) { MI_INFO *file; int i,j,error,deleted,rec_length,uniques=0; diff --git a/mysys/my_getopt.c b/mysys/my_getopt.c index b2ee6e0f373..21adb9374ce 100644 --- a/mysys/my_getopt.c +++ b/mysys/my_getopt.c @@ -572,7 +572,7 @@ static longlong eval_num_suffix (char *argument, int *error, char *option_name) In case of an error, set error value in *err. */ -longlong getopt_ll (char *arg, const struct my_option *optp, int *err) +static longlong getopt_ll(char *arg, const struct my_option *optp, int *err) { longlong num; @@ -596,7 +596,7 @@ longlong getopt_ll (char *arg, const struct my_option *optp, int *err) values. */ -static ulonglong getopt_ull (char *arg, const struct my_option *optp, int *err) +static ulonglong getopt_ull(char *arg, const struct my_option *optp, int *err) { ulonglong num; diff --git a/sql/ha_berkeley.cc b/sql/ha_berkeley.cc index 06acf4fa2e3..2154fbd7a32 100644 --- a/sql/ha_berkeley.cc +++ b/sql/ha_berkeley.cc @@ -1921,6 +1921,26 @@ int ha_berkeley::delete_table(const char *name) DBUG_RETURN(error); } +int ha_berkeley::rename_table(const char * from, const char * to) +{ + int error; + char from_buff[FN_REFLEN]; + char to_buff[FN_REFLEN]; + + if ((error= db_create(&file, db_env, 0))) + my_errno= error; + else + { + /* On should not do a file->close() after rename returns */ + error= file->rename(file, + fn_format(from_buff, from, "", ha_berkeley_ext, 2 | 4), + NULL, fn_format(to_buff, to, "", ha_berkeley_ext, + 2 | 4), 0); + } + return error; +} + + /* How many seeks it will take to read through the table This is to be comparable to the number returned by records_in_range so @@ -2080,7 +2100,7 @@ int ha_berkeley::analyze(THD* thd, HA_CHECK_OPT* check_opt) free(stat); stat=0; } - if (key_file[i]->stat(key_file[i], (void*) &stat, 0, 0)) + if ((key_file[i]->stat)(key_file[i], (void*) &stat, 0, 0)) goto err; /* purecov: inspected */ share->rec_per_key[i]= (stat->bt_ndata / (stat->bt_nkeys ? stat->bt_nkeys : 1)); @@ -2093,7 +2113,7 @@ int ha_berkeley::analyze(THD* thd, HA_CHECK_OPT* check_opt) free(stat); stat=0; } - if (file->stat(file, (void*) &stat, 0, 0)) + if ((file->stat)(file, (void*) &stat, 0, 0)) goto err; /* purecov: inspected */ } pthread_mutex_lock(&share->mutex); diff --git a/sql/ha_berkeley.h b/sql/ha_berkeley.h index f2a81d123f1..d2dc5e3216d 100644 --- a/sql/ha_berkeley.h +++ b/sql/ha_berkeley.h @@ -152,6 +152,7 @@ class ha_berkeley: public handler int create(const char *name, register TABLE *form, HA_CREATE_INFO *create_info); int delete_table(const char *name); + int rename_table(const char* from, const char* to); THR_LOCK_DATA **store_lock(THD *thd, THR_LOCK_DATA **to, enum thr_lock_type lock_type); diff --git a/sql/mini_client.cc b/sql/mini_client.cc index 5600983817b..38b3c22b91b 100644 --- a/sql/mini_client.cc +++ b/sql/mini_client.cc @@ -542,10 +542,13 @@ mc_mysql_connect(MYSQL *mysql,const char *host, const char *user, bzero((char*) &UNIXaddr,sizeof(UNIXaddr)); UNIXaddr.sun_family = AF_UNIX; strmov(UNIXaddr.sun_path, unix_socket); - if (mc_sock_connect(sock,(struct sockaddr *) &UNIXaddr, sizeof(UNIXaddr), + if (mc_sock_connect(sock, + my_reinterpret_cast(struct sockaddr *) (&UNIXaddr), + sizeof(UNIXaddr), mysql->options.connect_timeout) <0) { - DBUG_PRINT("error",("Got error %d on connect to local server",socket_errno)); + DBUG_PRINT("error",("Got error %d on connect to local server", + socket_errno)); net->last_errno=CR_CONNECTION_ERROR; sprintf(net->last_error,ER(net->last_errno),unix_socket,socket_errno); goto error; @@ -632,7 +635,9 @@ mc_mysql_connect(MYSQL *mysql,const char *host, const char *user, my_gethostbyname_r_free(); } sock_addr.sin_port = (ushort) htons((ushort) port); - if (mc_sock_connect(sock,(struct sockaddr *) &sock_addr, sizeof(sock_addr), + if (mc_sock_connect(sock, + my_reinterpret_cast(struct sockaddr *) (&sock_addr), + sizeof(sock_addr), mysql->options.connect_timeout) <0) { DBUG_PRINT("error",("Got error %d on connect to '%s'", diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc index 599c31d43ca..a0336d0b50b 100644 --- a/sql/sql_parse.cc +++ b/sql/sql_parse.cc @@ -497,7 +497,8 @@ check_connections(THD *thd) { vio_in_addr(net->vio,&thd->remote.sin_addr); thd->host=ip_to_hostname(&thd->remote.sin_addr,&connect_errors); - thd->host[strnlen(thd->host, HOSTNAME_LENGTH)]= 0; + /* Cut very long hostnames to avoid possible overflows */ + thd->host[min(strlen(thd->host), HOSTNAME_LENGTH)]= 0; if (connect_errors > max_connect_errors) return(ER_HOST_IS_BLOCKED); } @@ -2012,7 +2013,8 @@ mysql_execute_command(void) goto error; } walk->lock_type= auxi->lock_type; - auxi->table= (TABLE *) walk; // Remember corresponding table + // Store address to table as we need it later + auxi->table= my_reinterpret_cast(TABLE *) (walk); } if (add_item_to_list(new Item_null())) { @@ -2025,7 +2027,8 @@ mysql_execute_command(void) break; /* Fix tables-to-be-deleted-from list to point at opened tables */ for (auxi=(TABLE_LIST*) aux_tables ; auxi ; auxi=auxi->next) - auxi->table= ((TABLE_LIST*) auxi->table)->table; + auxi->table= (my_reinterpret_cast(TABLE_LIST*) (auxi->table))->table; + if (!thd->fatal_error && (result= new multi_delete(thd,aux_tables, table_count))) { @@ -3321,7 +3324,7 @@ static bool create_total_list(THD *thd, LEX *lex, TABLE_LIST **result) } else aux->shared=1; // Mark that it's used twice - aux->table=(TABLE *) cursor; + aux->table= my_reinterpret_cast(TABLE *) (cursor); } } } diff --git a/sql/sql_union.cc b/sql/sql_union.cc index 8cead6596b4..4e36ccafefc 100644 --- a/sql/sql_union.cc +++ b/sql/sql_union.cc @@ -52,7 +52,7 @@ int mysql_union(THD *thd, LEX *lex,select_result *result) { if (cursor->do_redirect) // False if CUBE/ROLLUP { - cursor->table= ((TABLE_LIST*) cursor->table)->table; + cursor->table= (my_reinterpret_cast(TABLE_LIST*) (cursor->table))->table; cursor->do_redirect= 0; } } diff --git a/sql/table.cc b/sql/table.cc index 62163819599..7e284c89871 100644 --- a/sql/table.cc +++ b/sql/table.cc @@ -144,7 +144,7 @@ int openfrm(const char *name, const char *alias, uint db_stat, uint prgflag, bzero((char*) keyinfo,n_length); outparam->key_info=keyinfo; outparam->max_key_length= outparam->total_key_length= 0; - key_part= (KEY_PART_INFO*) (keyinfo+keys); + key_part= my_reinterpret_cast(KEY_PART_INFO*) (keyinfo+keys); strpos=disk_buff+6; ulong *rec_per_key; diff --git a/tools/mysqlmanager.c b/tools/mysqlmanager.c index e6fab63c5b3..790a5d56b5a 100644 --- a/tools/mysqlmanager.c +++ b/tools/mysqlmanager.c @@ -1241,7 +1241,7 @@ static void handle_child(int __attribute__((unused)) sig) signal(SIGCHLD,handle_child); } -struct manager_thd* manager_thd_new(Vio* vio) +static struct manager_thd* manager_thd_new(Vio* vio) { struct manager_thd* tmp; if (!(tmp=(struct manager_thd*)my_malloc(sizeof(*tmp), |