diff options
author | wens <wens@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2009-02-01 23:48:41 +0800 |
---|---|---|
committer | wens <wens@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2009-02-01 23:48:41 +0800 |
commit | e7c8f48700a5f6e70f4c4d7e5f8171ffdc06ff6d (patch) | |
tree | 4158c7f362b07f737a3a6790241f1970c491afe2 /innbbsd/inntobbs.c | |
parent | eb02b264ab76ed138546da08deba14e64ffc22e1 (diff) | |
download | pttbbs-e7c8f48700a5f6e70f4c4d7e5f8171ffdc06ff6d.tar pttbbs-e7c8f48700a5f6e70f4c4d7e5f8171ffdc06ff6d.tar.gz pttbbs-e7c8f48700a5f6e70f4c4d7e5f8171ffdc06ff6d.tar.bz2 pttbbs-e7c8f48700a5f6e70f4c4d7e5f8171ffdc06ff6d.tar.lz pttbbs-e7c8f48700a5f6e70f4c4d7e5f8171ffdc06ff6d.tar.xz pttbbs-e7c8f48700a5f6e70f4c4d7e5f8171ffdc06ff6d.tar.zst pttbbs-e7c8f48700a5f6e70f4c4d7e5f8171ffdc06ff6d.zip |
Fix some compile warnings
Remove unused code
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@4437 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'innbbsd/inntobbs.c')
-rw-r--r-- | innbbsd/inntobbs.c | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/innbbsd/inntobbs.c b/innbbsd/inntobbs.c index b2ca4331..2a22f5aa 100644 --- a/innbbsd/inntobbs.c +++ b/innbbsd/inntobbs.c @@ -23,22 +23,22 @@ typedef struct Header { #include <string.h> header_t headertable[] = { - "Subject", SUBJECT_H, - "From", FROM_H, - "Date", DATE_H, - "Message-ID", MID_H, - "Newsgroups", NEWSGROUPS_H, - "NNTP-Posting-Host", NNTPPOSTINGHOST_H, - "NNTP-Host", NNTPHOST_H, - "Control", CONTROL_H, - "Path", PATH_H, - "Organization", ORGANIZATION_H, - "X-Auth-From", X_Auth_From_H, - "Approved", APPROVED_H, - "Distribution", DISTRIBUTION_H, - "Keywords", KEYWORDS_H, - "Summary", SUMMARY_H, - "References", REFERENCES_H, + {"Subject", SUBJECT_H}, + {"From", FROM_H}, + {"Date", DATE_H}, + {"Message-ID", MID_H}, + {"Newsgroups", NEWSGROUPS_H}, + {"NNTP-Posting-Host", NNTPPOSTINGHOST_H}, + {"NNTP-Host", NNTPHOST_H}, + {"Control", CONTROL_H}, + {"Path", PATH_H}, + {"Organization", ORGANIZATION_H}, + {"X-Auth-From", X_Auth_From_H}, + {"Approved", APPROVED_H}, + {"Distribution", DISTRIBUTION_H}, + {"Keywords", KEYWORDS_H}, + {"Summary", SUMMARY_H}, + {"References", REFERENCES_H}, }; char *HEADER[LASTHEADER]; @@ -59,7 +59,7 @@ isexcluded(path1, nl) { char path2[1024]; /* path2 = (char*)mymalloc(strlen(nl->node) + 3); */ - sprintf(path2, "!%.*s!", sizeof path2 - 3, nl->node); + sprintf(path2, "!%.*s!", (int)(sizeof(path2) - 3), nl->node); if (strstr(path1, path2) != NULL) return 1; if (nl->exclusion && *nl->exclusion) { @@ -68,7 +68,7 @@ isexcluded(path1, nl) exclude && *exclude; ptr = strchr(exclude, ',')) { if (ptr) *ptr = '\0'; - sprintf(path2, "!%.*s!", sizeof path2 - 3, exclude); + sprintf(path2, "!%.*s!", (int)(sizeof(path2) - 3), exclude); if (strstr(path1, path2) != NULL) return 1; if (ptr) { |