summaryrefslogtreecommitdiff
path: root/libiberty/d-demangle.c
diff options
context:
space:
mode:
authoribuclaw <ibuclaw@138bc75d-0d04-0410-961f-82ee72b054a4>2015-05-16 16:49:25 +0000
committeribuclaw <ibuclaw@138bc75d-0d04-0410-961f-82ee72b054a4>2015-05-16 16:49:25 +0000
commitfb21d482ef9b0baf3051e7e9b4a5be02dd483aba (patch)
treed9dbbe92e857ece9d49d7c5371ef1cc9e42ca222 /libiberty/d-demangle.c
parent2cd5d370312439bffecacc10fa1665e735472a0b (diff)
downloadgcc-fb21d482ef9b0baf3051e7e9b4a5be02dd483aba.tar.gz
libiberty/ChangeLog:
2015-05-16 Iain Buclaw <ibuclaw@gdcproject.org> * d-demangle.c (dlang_call_convention): Return NULL if have reached the end of the symbol, but expected something to read. (dlang_attributes): Likewise. (dlang_function_type): Likewise. (dlang_type): Likewise. (dlang_identifier): Likewise. (dlang_value): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@223241 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libiberty/d-demangle.c')
-rw-r--r--libiberty/d-demangle.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/libiberty/d-demangle.c b/libiberty/d-demangle.c
index 10585214a9f..09984782e38 100644
--- a/libiberty/d-demangle.c
+++ b/libiberty/d-demangle.c
@@ -185,7 +185,7 @@ static const char *
dlang_call_convention (string *decl, const char *mangled)
{
if (mangled == NULL || *mangled == '\0')
- return mangled;
+ return NULL;
switch (*mangled)
{
@@ -221,7 +221,7 @@ static const char *
dlang_attributes (string *decl, const char *mangled)
{
if (mangled == NULL || *mangled == '\0')
- return mangled;
+ return NULL;
while (*mangled == 'N')
{
@@ -280,7 +280,7 @@ dlang_function_type (string *decl, const char *mangled)
size_t szattr, szargs, sztype;
if (mangled == NULL || *mangled == '\0')
- return mangled;
+ return NULL;
/* The order of the mangled string is:
CallConvention FuncAttrs Arguments ArgClose Type
@@ -380,7 +380,7 @@ static const char *
dlang_type (string *decl, const char *mangled)
{
if (mangled == NULL || *mangled == '\0')
- return mangled;
+ return NULL;
switch (*mangled)
{
@@ -600,7 +600,7 @@ static const char *
dlang_identifier (string *decl, const char *mangled)
{
if (mangled == NULL || *mangled == '\0')
- return mangled;
+ return NULL;
if (ISDIGIT (*mangled))
{
@@ -1061,7 +1061,7 @@ static const char *
dlang_value (string *decl, const char *mangled, const char *name, char type)
{
if (mangled == NULL || *mangled == '\0')
- return mangled;
+ return NULL;
switch (*mangled)
{