strcat(users," ");
while(fgets(buf,sizeof(buf),fp_in)!=NULL) {
- getword(user,buf,' ');
+ if (getword(user,sizeof(user),buf,' ')<0) {
+ printf("SARG: Maybe you have an invalid user in the %s file of the siteuser.\n",general2);
+ exit(1);
+ }
if(strcmp(user,"TOTAL") == 0)
continue;
if(userip)
if(strcmp(Ip2Name,"yes") == 0)
ip2name(user);
- getword(nacc,buf,' ');
+ if (getword(nacc,sizeof(nacc),buf,' ')<0){
+ printf("SARG: Maybe you have an invalid number of access in your %s file of the siteuser.\n",general2);
+ exit(1);
+ }
if (atoi(nacc) > 0) nsitesusers = 1;
- getword(nbytes,buf,' ');
- getword(url,buf,' ');
+ if (getword(nbytes,sizeof(nbytes),buf,' ')<0){
+ printf("SARG: Maybe you have an invalid number of bytes in your %s file of the siteuser.\n",general2);
+ exit(1);
+ }
+ if (getword(url,sizeof(url),buf,' ')<0) {
+ printf("SARG: Maybe you have an invalid url in your %s file of the siteuser.\n",general2);
+ exit(1);
+ }
if(!regs) {
strcpy(ourl,url);