AVRO-1161. C: Fix memory leak in avro{append,cat,mod,pipe} Patch from me, analysis and description of fix contributed by Lucas Martin-King and Maxim Pugachev.