|
|

楼主 |
发表于 2006-1-4 22:19:45
|
显示全部楼层
patch 如下:
[php]--- src/data.c 2006-01-04 22:13:42.000000000 +0800
+++ src/data.c 2006-01-04 22:08:00.000000000 +0800
@@ -55,7 +55,6 @@
fprintf(fp,"play_port=%d\n",iPlayPort);
fclose(fp);
- loadconfig();
return TRUE;
}
@@ -72,12 +71,15 @@
fp=fopen(strPath,"rt");
- if(!fp && !saveconfig())
+ if(!fp)
{
-// saveconfig();
-// loadconfig();
- fprintf(stderr,"Warning: You can not use the `config' file! \n");
- return FALSE;
+ if(!saveconfig())
+ {
+ fprintf(stderr,"Warning: You can not use the `config' file! \n");
+ return FALSE;
+ }
+ loadconfig();
+ return TRUE;
}
while(1)
[/php] |
|