Commit de009a79 authored by Mark Hills's avatar Mark Hills
Browse files

Simplify

It's valid to call free() on a NULL pointer, so use this.
parent f39de371
......@@ -53,8 +53,7 @@ void index_init(struct index *ls)
void index_clear(struct index *ls)
{
if (ls->record != NULL)
free(ls->record);
free(ls->record); /* may be NULL */
}
/*
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment