Coverity 420

Remove dead code and add a g_assert_not_reached() at a spot we can definitely never reach.

change a if(x)g_free(x) to a g_free(x)
since g_free(NULL) is just a nop.



svn path=/trunk/; revision=36238
This commit is contained in:
Ronnie Sahlberg 2011-03-22 09:05:26 +00:00
parent 423e428441
commit ea9e664fc9
1 changed files with 4 additions and 7 deletions

View File

@ -445,18 +445,15 @@ static void analyze_gop(mate_gop* gop) {
break; break;
} }
/** XXX: Can't get here because of "breaks" above; Incorrect code someplace ?? */ /** Can't get here because of "breaks" above */
delete_avpl(gogkey_match,TRUE); g_assert_not_reached();
gogkey_match = NULL;
} }
if (key) g_free(key);
key = NULL;
dbg_print (dbg_gog,1,dbg_facility,"analyze_gop: no gogkey_match: %s",key); dbg_print (dbg_gog,1,dbg_facility,"analyze_gop: no gogkey_match: %s",key);
} /* while */ } /* while */
if (key) g_free(key); g_free(key);
key = NULL;
if (gogkey_match) delete_avpl(gogkey_match,TRUE); if (gogkey_match) delete_avpl(gogkey_match,TRUE);