Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

cppCheck: Suspicious condition.

AFAIK, there is no actual problem with the existing code.  'rv' would only not have the 'expected' value, but the execution
path would remain the same.
However, the patched code is more logical. We put the returned value in 'rv', then test it against 0.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1407853 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information...
commit 0b404c26311703c18aca4a74902aa2e77740fce3 1 parent 2363d7a
Christophe Jaillet authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  modules/aaa/mod_authz_dbd.c
View
2  modules/aaa/mod_authz_dbd.c
@@ -163,7 +163,7 @@ static int authz_dbd_login(request_rec *r, authz_dbd_cfg *cfg,
/* OK, this is non-critical; we can just not-redirect */
}
else if ((rv = apr_dbd_pvselect(dbd->driver, r->pool, dbd->handle,
- &res, query, 0, r->user, NULL) == 0)) {
+ &res, query, 0, r->user, NULL)) == 0) {
for (rv = apr_dbd_get_row(dbd->driver, r->pool, res, &row, -1);
rv != -1;
rv = apr_dbd_get_row(dbd->driver, r->pool, res, &row, -1)) {
Please sign in to comment.
Something went wrong with that request. Please try again.