--- a/plug-ins/common/file-tga.c	2017-08-22 19:57:28.000000000 +0200
+++ b/plug-ins/common/file-tga.c	2017-11-18 15:41:51.507053080 +0100
@@ -1027,7 +1027,14 @@ ReadImage (FILE        *fp,
       itype = GIMP_RGB;
 
       if (info->alphaBits)
-        dtype = GIMP_RGBA_IMAGE;
+        {
+          if (info->bytes != 4)
+            {
+              g_message ("RGBA image must have 32 bits per pixel");
+              return -1;
+            }
+          dtype = GIMP_RGBA_IMAGE;
+        }
       else
         dtype = GIMP_RGB_IMAGE;
       break;
