about summary refs log tree commit diff
path: root/converter/other/pamtotga.c
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2008-06-22 16:34:14 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2008-06-22 16:34:14 +0000
commit09f70ec67186bb10dbd252650210bff2daa70ec7 (patch)
treef27e1a57d5fe813f3a7c6d33c7c56fb98880d1c1 /converter/other/pamtotga.c
parenta2da607bd4eed604a9e7d59528886b24de27222f (diff)
downloadnetpbm-mirror-09f70ec67186bb10dbd252650210bff2daa70ec7.tar.gz
netpbm-mirror-09f70ec67186bb10dbd252650210bff2daa70ec7.tar.xz
netpbm-mirror-09f70ec67186bb10dbd252650210bff2daa70ec7.zip
Release 10.35.46
git-svn-id: http://svn.code.sf.net/p/netpbm/code/stable@654 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'converter/other/pamtotga.c')
-rw-r--r--converter/other/pamtotga.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/converter/other/pamtotga.c b/converter/other/pamtotga.c
index 1e0808ed..6c8769ed 100644
--- a/converter/other/pamtotga.c
+++ b/converter/other/pamtotga.c
@@ -461,7 +461,8 @@ computeTgaHeader(struct pam *          const pamP,
 static void
 releaseTgaHeader(struct ImageHeader const tgaHeader) {
 
-    strfree(tgaHeader.Id);
+    if (tgaHeader.IdLength > 0)
+        strfree(tgaHeader.Id);
 }