diff options
Diffstat (limited to 'libiberty/cplus-dem.c')
-rw-r--r-- | libiberty/cplus-dem.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libiberty/cplus-dem.c b/libiberty/cplus-dem.c index 6d58bd8..4f29d54 100644 --- a/libiberty/cplus-dem.c +++ b/libiberty/cplus-dem.c @@ -4471,7 +4471,8 @@ remember_Btype (struct work_stuff *work, const char *start, char *tem; tem = XNEWVEC (char, len + 1); - memcpy (tem, start, len); + if (len > 0) + memcpy (tem, start, len); tem[len] = '\0'; work -> btypevec[index] = tem; } |