OSDN Git Service

2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
authormikael <mikael@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 6 Oct 2010 14:19:30 +0000 (14:19 +0000)
committermikael <mikael@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 6 Oct 2010 14:19:30 +0000 (14:19 +0000)
* module.c (read_module): Remove useless string duplication.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@165028 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/fortran/ChangeLog
gcc/fortran/module.c

index 8d8fc7f..b4252ec 100644 (file)
@@ -1,5 +1,9 @@
 2010-10-06  Mikael Morin  <mikael@gcc.gnu.org>
 
+       * module.c (read_module): Remove useless string duplication.
+
+2010-10-06  Mikael Morin  <mikael@gcc.gnu.org>
+
        * gfortranspec.c (append_arg): Remove commented code.
 
 2010-10-06  Mikael Morin  <mikael@gcc.gnu.org>
index c90fe0d..02f5756 100644 (file)
@@ -4372,8 +4372,8 @@ read_module (void)
            p = name;
 
          /* Exception: Always import vtabs & vtypes.  */
-         if (p == NULL && (strcmp (xstrndup (name,5), "vtab$") == 0
-                           || strcmp (xstrndup (name,6), "vtype$") == 0))
+         if (p == NULL && (strncmp (name, "vtab$", 5) == 0
+                           || strncmp (name, "vtype$", 6) == 0))
            p = name;
 
          /* Skip symtree nodes not in an ONLY clause, unless there