summaryrefslogtreecommitdiff
path: root/usr.sbin/httpd
diff options
context:
space:
mode:
authorPhilip Guenther <guenther@cvs.openbsd.org>2013-08-22 04:43:42 +0000
committerPhilip Guenther <guenther@cvs.openbsd.org>2013-08-22 04:43:42 +0000
commit323d1abbc45a9dfeae3d39b5f8cc041dc4b73bd1 (patch)
tree64ea330e44da28fb9da88722be4cb4e200afe707 /usr.sbin/httpd
parent31003a7e68970e14de72e158246cccd33cccc1e7 (diff)
Correct format string mismatches turned up by -Wformat=2
suggestions and ok millert@
Diffstat (limited to 'usr.sbin/httpd')
-rw-r--r--usr.sbin/httpd/src/main/http_protocol.c10
-rw-r--r--usr.sbin/httpd/src/modules/experimental/mod_auth_digest.c4
2 files changed, 7 insertions, 7 deletions
diff --git a/usr.sbin/httpd/src/main/http_protocol.c b/usr.sbin/httpd/src/main/http_protocol.c
index e26c60ab883..f2a91318257 100644
--- a/usr.sbin/httpd/src/main/http_protocol.c
+++ b/usr.sbin/httpd/src/main/http_protocol.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: http_protocol.c,v 1.38 2013/08/08 03:16:13 guenther Exp $ */
+/* $OpenBSD: http_protocol.c,v 1.39 2013/08/22 04:43:41 guenther Exp $ */
/* ====================================================================
* The Apache Software License, Version 1.1
@@ -1349,14 +1349,14 @@ API_EXPORT(void) ap_note_digest_auth_failure(request_rec *r)
*/
char * nonce_prefix = ap_md5(r->pool,
(unsigned char *)
- ap_psprintf(r->pool, "%s%lu",
- ap_auth_nonce(r), r->request_time));
+ ap_psprintf(r->pool, "%s%lld",
+ ap_auth_nonce(r), (long long)r->request_time));
ap_table_setn(r->err_headers_out,
r->proxyreq == STD_PROXY ? "Proxy-Authenticate"
: "WWW-Authenticate",
- ap_psprintf(r->pool, "Digest realm=\"%s\", nonce=\"%s%lu\"",
- ap_auth_name(r), nonce_prefix, r->request_time));
+ ap_psprintf(r->pool, "Digest realm=\"%s\", nonce=\"%s%lld\"",
+ ap_auth_name(r), nonce_prefix, (long long)r->request_time));
}
API_EXPORT(int) ap_get_basic_auth_pw(request_rec *r, const char **pw)
diff --git a/usr.sbin/httpd/src/modules/experimental/mod_auth_digest.c b/usr.sbin/httpd/src/modules/experimental/mod_auth_digest.c
index 0115ec15208..3aaef8eb29d 100644
--- a/usr.sbin/httpd/src/modules/experimental/mod_auth_digest.c
+++ b/usr.sbin/httpd/src/modules/experimental/mod_auth_digest.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mod_auth_digest.c,v 1.22 2008/05/25 11:46:27 mbalmer Exp $ */
+/* $OpenBSD: mod_auth_digest.c,v 1.23 2013/08/22 04:43:41 guenther Exp $ */
/* ====================================================================
* The Apache Software License, Version 1.1
@@ -884,7 +884,7 @@ static int check_nonce(request_rec *r, digest_header_rec *resp,
if (strlen(resp->nonce) != NONCE_LEN) {
ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, r,
- "Digest: invalid nonce %s received - length is not %d",
+ "Digest: invalid nonce %s received - length is not %zu",
resp->nonce, NONCE_LEN);
note_digest_auth_failure(r, conf, resp, 1);
return AUTH_REQUIRED;