Commit b91221b
authored
optimize: fix potential null pointer dereference found by coverity (#2051)
deref_ptr: Directly dereferencing pointer ctx.
1143 *ctx = ngx_http_get_module_ctx(r, ngx_http_lua_module);
CID 258020 (#1 of 1): Dereference before null check (REVERSE_INULL)check_after_deref: Null-checking ctx suggests that it may be null, but it has already been dereferenced on all paths leading to the check.
1144 if (ctx == NULL) {
1145 return NGX_HTTP_LUA_FFI_NO_REQ_CTX;
1146 }1 parent 381e9b3 commit b91221b
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1141 | 1141 | | |
1142 | 1142 | | |
1143 | 1143 | | |
1144 | | - | |
| 1144 | + | |
1145 | 1145 | | |
1146 | 1146 | | |
1147 | 1147 | | |
| |||
0 commit comments