]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - libgfortran/generated/transpose_c16.c
Introduce xmallocarray, an overflow checking variant of xmalloc.
[thirdparty/gcc.git] / libgfortran / generated / transpose_c16.c
index f11128eddd051c290fec33dce9089263c670a562..044509f67f0aefb766c05d575f5b81e502c498df 100644 (file)
@@ -60,7 +60,8 @@ transpose_c16 (gfc_array_c16 * const restrict ret,
       GFC_DIMENSION_SET(ret->dim[1], 0, GFC_DESCRIPTOR_EXTENT(source,0) - 1,
                        GFC_DESCRIPTOR_EXTENT(source, 1));
 
-      ret->base_addr = xmalloc (sizeof (GFC_COMPLEX_16) * size0 ((array_t *) ret));
+      ret->base_addr = xmallocarray (size0 ((array_t *) ret), 
+                                     sizeof (GFC_COMPLEX_16));
       ret->offset = 0;
     } else if (unlikely (compile_options.bounds_check))
     {