From: Cliff Woolley Date: Mon, 11 Jun 2001 14:46:30 +0000 (+0000) Subject: Silence gcc warning about rv being used when possibly uninitialized. That X-Git-Tag: 2.0.19~86 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6f7f33a5113d7d151361327b20492a1be388c8c7;p=thirdparty%2Fapache%2Fhttpd.git Silence gcc warning about rv being used when possibly uninitialized. That can only happen if n<=1 (ie, a bad parameter value), so I figure APR_EINVAL is the correct default value. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89333 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/support/htdigest.c b/support/htdigest.c index 37c0485ed63..511921089fd 100644 --- a/support/htdigest.c +++ b/support/htdigest.c @@ -122,7 +122,7 @@ static int getline(char *s, int n, apr_file_t *f) { register int i = 0; char ch; - apr_status_t rv; + apr_status_t rv = APR_EINVAL; while (i < (n - 1) && ((rv = apr_file_getc(&ch, f)) == APR_SUCCESS) && (ch != '\n')) {