|
Lines 818-841
Link Here
|
| 818 |
i = 0; |
818 |
i = 0; |
| 819 |
while (*cp >= '0' && *cp <= '9') |
819 |
while (*cp >= '0' && *cp <= '9') |
| 820 |
i = i * 10 + (*cp++ - '0'); |
820 |
i = i * 10 + (*cp++ - '0'); |
| 821 |
fino = i; |
821 |
fino = i; |
| 822 |
} else if (line[0] == 'H') { |
822 |
} else if (line[0] == 'H') { |
| 823 |
strcpy(fromhost, line+1); |
823 |
strncpy(fromhost, line+1, sizeof(fromhost) - 1); |
|
|
824 |
fromhost[sizeof(fromhost)-1] = '\0'; |
| 824 |
if (class[0] == '\0') |
825 |
if (class[0] == '\0') |
|
|
826 |
{ |
| 825 |
strncpy(class, line+1, sizeof(class) - 1); |
827 |
strncpy(class, line+1, sizeof(class) - 1); |
|
|
828 |
class[sizeof(class)-1] = '\0'; |
| 829 |
} |
| 826 |
} else if (line[0] == 'P') { |
830 |
} else if (line[0] == 'P') { |
| 827 |
strncpy(logname, line+1, sizeof(logname) - 1); |
831 |
strncpy(logname, line+1, sizeof(logname) - 1); |
|
|
832 |
logname[sizeof(logname)-1] = '\0'; |
| 828 |
if (pp->restricted) { /* restricted */ |
833 |
if (pp->restricted) { /* restricted */ |
| 829 |
if (getpwnam(logname) == NULL) { |
834 |
if (getpwnam(logname) == NULL) { |
| 830 |
sendmail(pp, line+1, NOACCT); |
835 |
sendmail(pp, line+1, NOACCT); |
| 831 |
err = ERROR; |
836 |
err = ERROR; |
| 832 |
break; |
837 |
break; |
| 833 |
} |
838 |
} |
| 834 |
} |
839 |
} |
| 835 |
} else if (line[0] == 'I') { |
840 |
} else if (line[0] == 'I') { |
| 836 |
strncpy(indent+2, line+1, sizeof(indent) - 3); |
841 |
strncpy(indent+2, line+1, sizeof(indent) - 3); |
|
|
842 |
indent[2+sizeof(indent)-3] = '\0'; |
| 837 |
} else if (line[0] >= 'a' && line[0] <= 'z') { |
843 |
} else if (line[0] >= 'a' && line[0] <= 'z') { |
| 838 |
strcpy(last, line); |
844 |
strcpy(last, line); |
| 839 |
while ((i = getline(cfp)) != 0) |
845 |
while ((i = getline(cfp)) != 0) |
| 840 |
if (strcmp(last, line)) |
846 |
if (strcmp(last, line)) |
| 841 |
break; |
847 |
break; |