• Kashif Rasul's avatar
    Fix issues raised by clang analyzer · 8fc2247c
    Kashif Rasul authored
    Modified by @antirez since the original fix to genInfoString() looked
    weak. Probably the clang analyzer complained about `section` being
    possibly NULL, and strcasecmp() called with a NULL pointer. In the
    practice this can never happen, still for the sake of correctness
    the right fix is not to modify only the first call, but to set `section`
    to the value of "default" if it happens to be NULL.
    
    Closes #1660
    8fc2247c
redis-cli.c 62.6 KB