#1971 Dereference before NULL check in nscd.c
Closed: Fixed None Opened 5 years ago by jhrozek.

193

CID 11852: Dereference before null check (REVERSE_INULL) [select issue]

CID 11853: Dereference before null check (REVERSE_INULL) [select issue]

CID 11851: Dereference before null check (REVERSE_INULL)check_after_deref: Null-checking "entry" suggests that it may be null, but it has already been dereferenced on all paths leading to the check.
194        if (entry   != NULL &&
195            service != NULL &&
196            enabled != NULL) {

I suggested the NULL checks during code review but reading the code now more carefully the worst case that can happen is that all pointers will point to "line" so maybe the checks can be removed. Please test with malformed lines (two out of three valid keywords etc).

Fields changed

coverity: 11851 => 11851,11852

Fields changed

coverity: 11851,11852 => 11851,11852,11853

Fields changed

patch: 0 => 1
status: new => assigned

A Coverity bug can be moved to 1.10 beta directly w/o waiting on the triage.

milestone: NEEDS_TRIAGE => SSSD 1.10 beta
resolution: => fixed
status: assigned => closed

Fields changed

rhbz: => 0

Metadata Update from @jhrozek:
- Issue assigned to okos
- Issue set to the milestone: SSSD 1.10 beta

2 years ago

Login to comment on this ticket.

Metadata