simplify code by relying on free(NULL) being a no-op
simplify code by relying on free(NULL) being a no-op

...and by avoiding an unnecessary variable and by not assigning NULL
when it's going to be re-assigned immediately after.

C99 says that free(NULL) is a no-op, so this should be safe.

rhansen/rpstir,rhansen/rpstir,rhansen/rpstir,rhansen/rpstir,rhansen/rpstir