From 3d8e3bc3cebd807bd32d8e9e11b0555aa24eb980 Mon Sep 17 00:00:00 2001 From: kcwu Date: Fri, 21 Sep 2007 00:17:59 +0000 Subject: * fix compile git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@3566 63ad8ddf-47c3-0310-b6dd-a9e9d9715204 --- util/shmctl.c | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'util') diff --git a/util/shmctl.c b/util/shmctl.c index 939fab39..42ba9415 100644 --- a/util/shmctl.c +++ b/util/shmctl.c @@ -980,24 +980,24 @@ int torb(int argc, char **argv) return 0; } -int fixbcache(int argc, char **argv) +void lockbcache(void) { - void lockbcache(void) - { - int i; - for( i = 0 ; i < 10 && SHM->Bbusystate ; ++i ){ - printf("SHM->Bbusystate is currently locked (value: %d). " - "please wait... ", SHM->Bbusystate); - sleep(1); - } - if( i == 10 ) - puts("steal bcache lock\n"); - SHM->Bbusystate = 1; - } - void unlockbcache(void) - { - SHM->Bbusystate = 0; + int i; + for( i = 0 ; i < 10 && SHM->Bbusystate ; ++i ){ + printf("SHM->Bbusystate is currently locked (value: %d). " + "please wait... ", SHM->Bbusystate); + sleep(1); } + if( i == 10 ) + puts("steal bcache lock\n"); + SHM->Bbusystate = 1; +} +void unlockbcache(void) +{ + SHM->Bbusystate = 0; +} +int fixbcache(int argc, char **argv) +{ int n, fd, bid, changed = 0; boardheader_t bh; @@ -1132,7 +1132,7 @@ int showstat(int argc, char *argv[]) if(argv[1] && strcmp(argv[1],"-c")==0) flag_clear=1; for(i=0; istatistic[i]); } if(flag_clear) -- cgit v1.2.3