bug-cflow
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug-cflow] [PATCH] Fix Segmentation fault of -s option


From: Naohiro Ooiwa
Subject: [bug-cflow] [PATCH] Fix Segmentation fault of -s option
Date: Fri, 26 Jun 2009 20:00:12 +0900
User-agent: Thunderbird 2.0.0.14 (X11/20080501)

Hi Sergey Poznyakoff

I found a little bug.

  # cflow-1.2/src/cflow -s main.c
  Segmentation fault

I fixed it.
Could you please check my patch?


Best Regards,
Naohiro Ooiwa


 main.c |    5 +++++
 1 file changed, 5 insertions(+)

--- cflow-1.2/src/main.c.orig   2007-06-27 23:16:46.000000000 +0900
+++ cflow-1.2/src/main.c        2009-06-26 19:08:50.000000000 +0900
@@ -257,6 +257,11 @@ symbol_override(const char *str)
      Symbol *sp;

      ptr = strchr(str, ':');
+
+     if (ptr == NULL) {
+         error(0, 0, _("no argument of symbol"));
+         return;
+     }
      if (*ptr == ':') {
          type = find_option_type(symbol_optype, ptr+1, 0);
          if (type == 0) {




reply via email to

[Prev in Thread] Current Thread [Next in Thread]