summaryrefslogtreecommitdiff
path: root/libgfortran/generated/minloc1_16_i2.c
diff options
context:
space:
mode:
Diffstat (limited to 'libgfortran/generated/minloc1_16_i2.c')
-rw-r--r--libgfortran/generated/minloc1_16_i2.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/libgfortran/generated/minloc1_16_i2.c b/libgfortran/generated/minloc1_16_i2.c
index dd80c0060b6..a035ef35ef2 100644
--- a/libgfortran/generated/minloc1_16_i2.c
+++ b/libgfortran/generated/minloc1_16_i2.c
@@ -99,10 +99,9 @@ minloc1_16_i2 (gfc_array_i16 * const restrict retarray,
retarray->elem_len = array->elem_len;
retarray->type = array->type;
- alloc_size = GFC_DESCRIPTOR_SM (retarray, rank-1)
- * extent[rank-1];
+ alloc_size = GFC_DESCRIPTOR_SM (retarray, rank-1) * extent[rank-1];
- retarray->base_addr = xmalloc (alloc_size);
+ retarray->base_addr = xmallocarray (alloc_size, sizeof (GFC_INTEGER_16));
if (alloc_size == 0)
{
/* Make sure we have a zero-sized array. */
@@ -295,8 +294,7 @@ mminloc1_16_i2 (gfc_array_i16 * const restrict retarray,
}
- alloc_size = GFC_DESCRIPTOR_SM (retarray, rank-1)
- * extent[rank-1];
+ alloc_size = GFC_DESCRIPTOR_SM (retarray, rank-1) * extent[rank-1];
retarray->offset = 0;
retarray->elem_len = array->elem_len;
@@ -309,7 +307,7 @@ mminloc1_16_i2 (gfc_array_i16 * const restrict retarray,
return;
}
else
- retarray->base_addr = xmalloc (alloc_size);
+ retarray->base_addr = xmallocarray (alloc_size, sizeof (GFC_INTEGER_16));
}
else
@@ -487,8 +485,7 @@ sminloc1_16_i2 (gfc_array_i16 * const restrict retarray,
retarray->type = array->type;
retarray->offset = 0;
- alloc_size = GFC_DESCRIPTOR_SM (retarray, rank-1)
- * extent[rank-1];
+ alloc_size = GFC_DESCRIPTOR_SM (retarray, rank-1) * extent[rank-1];
if (alloc_size == 0)
{
@@ -497,7 +494,7 @@ sminloc1_16_i2 (gfc_array_i16 * const restrict retarray,
return;
}
else
- retarray->base_addr = xmalloc (alloc_size);
+ retarray->base_addr = xmallocarray (alloc_size, sizeof (GFC_INTEGER_16));
}
else
{