$NetBSD: patch-aa,v 1.4 2001/10/07 22:44:21 tron Exp $ --- bidwatcher.cpp.orig Thu Jul 5 02:31:54 2001 +++ bidwatcher.cpp Mon Oct 8 00:42:19 2001 @@ -639,7 +639,7 @@ if(proxyurl!=NULL) delete(proxyurl); if(strlen(proxystring)>2) - proxyurl=new URL(g_strdup_printf("http://%s",proxystring),NULL); + proxyurl=new URL(g_strdup_printf("http://%s/",proxystring),NULL); else proxyurl=NULL; if(timesyncurl!=NULL) delete(timesyncurl); @@ -1712,11 +1712,15 @@ fprintf(file,"option trackbids %s\n", trackBids?"yes":"no"); fprintf(file,"option updateonstartup %s\n", doStartup?"yes":"no"); fprintf(file,"option autodelete %s\n", autoDelete?"yes":"no"); - fprintf(file,"option snipedelay %.2f\n", snipeDelay); + fprintf(file,"option snipedelay %.d\n", snipeDelay); if(clockIsSet) fprintf(file,"option timediff %d\n",timeDiff); fprintf(file, "user %s %s\n",authID,authPASS); - fprintf(file, "option browser %s\n",browserPATH); - fprintf(file, "option proxy %s\n",proxystring); + if (browserPATH[0]!='\0') + fprintf(file, "option browser %s\n",browserPATH); + if (emailPATH[0]!='\0') + fprintf(file, "option email %s\n",emailPATH); + if (proxystring[0]!='\0') + fprintf(file, "option proxy %s\n",proxystring); for ( int i=0; i < aucIdx; i++ ) { fprintf(file,"auction %u\n",auction[i]->ItemNumber); @@ -2508,7 +2512,7 @@ if(proxyurl!=NULL) delete(proxyurl); if(strlen(proxystring)>2) - proxyurl=new URL(g_strdup_printf("http://%s",proxystring),NULL); + proxyurl=new URL(g_strdup_printf("http://%s/",proxystring),NULL); else proxyurl=NULL; if(timesyncurl!=NULL) delete(timesyncurl); @@ -2564,7 +2568,7 @@ } if(!strcasecmp(which,"snipedelay")) { - fscanf(file,"%.2f",&snipeDelay); + fscanf(file,"%d",&snipeDelay); recognized=1; } @@ -2575,12 +2579,17 @@ } if(!strcasecmp(which,"browser")) { - fscanf(file,"%199[^\n]",browserPATH); + fscanf(file,"%199s[^\n]",browserPATH); + recognized=1; + } + + if(!strcasecmp(which,"email")) { + fscanf(file,"%199s[^\n]",emailPATH); recognized=1; } if(!strcasecmp(which,"proxy")) { - fscanf(file,"%199[^\n]",proxystring); + fscanf(file,"%199s[^\n]",proxystring); recognized=1; if(strspn(proxystring," ")==strlen(proxystring)) proxystring[0]='\0'; } @@ -2618,7 +2627,7 @@ fclose(file); if(proxyurl!=NULL) delete(proxyurl); if(strlen(proxystring)>2) - proxyurl=new URL(g_strdup_printf("http://%s",proxystring),NULL); + proxyurl=new URL(g_strdup_printf("http://%s/",proxystring),NULL); else proxyurl=NULL; if(timesyncurl!=NULL) delete(timesyncurl);