summaryrefslogtreecommitdiffstats
path: root/usr.sbin/httpd/src
diff options
context:
space:
mode:
authorray <ray@openbsd.org>2007-02-20 01:44:16 +0000
committerray <ray@openbsd.org>2007-02-20 01:44:16 +0000
commit0420c874a690622bb92bd10a07d234035b0874ed (patch)
tree13705e7bcb87d504ab07d5abfe98d4025b5c3e8c /usr.sbin/httpd/src
parentknf found while fixing another bug (diff)
downloadwireguard-openbsd-0420c874a690622bb92bd10a07d234035b0874ed.tar.xz
wireguard-openbsd-0420c874a690622bb92bd10a07d234035b0874ed.zip
Change hard coded numbers to sizeof(buf). Also change some
sizeof(buf) - 1 to sizeof(buf), since fgets takes the whole buffer size. Based on diff from Charles Longeau <chl at tuxfamily dot org> long ago. OK millert@.
Diffstat (limited to 'usr.sbin/httpd/src')
-rw-r--r--usr.sbin/httpd/src/modules/standard/mod_cern_meta.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/httpd/src/modules/standard/mod_cern_meta.c b/usr.sbin/httpd/src/modules/standard/mod_cern_meta.c
index 766f6a81515..44a252bf3b1 100644
--- a/usr.sbin/httpd/src/modules/standard/mod_cern_meta.c
+++ b/usr.sbin/httpd/src/modules/standard/mod_cern_meta.c
@@ -238,7 +238,7 @@ static int scan_meta_file(request_rec *r, FILE *f)
table *tmp_headers;
tmp_headers = ap_make_table(r->pool, 5);
- while (fgets(w, MAX_STRING_LEN - 1, f) != NULL) {
+ while (fgets(w, sizeof(w), f) != NULL) {
/* Delete terminal (CR?)LF */