aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran
diff options
context:
space:
mode:
authorMikael Morin <mikael@gcc.gnu.org>2010-10-06 14:19:30 +0000
committerMikael Morin <mikael@gcc.gnu.org>2010-10-06 14:19:30 +0000
commit3e212b5d2bc8746d8e1a9ed86d3122601d797036 (patch)
treeeda5abca351d14ba540db16153d82550ac2d3e51 /gcc/fortran
parent476bed6606c938c33c253ef4693ad6c15275eb69 (diff)
downloadgcc-3e212b5d2bc8746d8e1a9ed86d3122601d797036.zip
gcc-3e212b5d2bc8746d8e1a9ed86d3122601d797036.tar.gz
gcc-3e212b5d2bc8746d8e1a9ed86d3122601d797036.tar.bz2
module.c (read_module): Remove useless string duplication.
2010-10-06 Mikael Morin <mikael@gcc.gnu.org> * module.c (read_module): Remove useless string duplication. From-SVN: r165028
Diffstat (limited to 'gcc/fortran')
-rw-r--r--gcc/fortran/ChangeLog4
-rw-r--r--gcc/fortran/module.c4
2 files changed, 6 insertions, 2 deletions
diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog
index 8d8fc7f..b4252ec 100644
--- a/gcc/fortran/ChangeLog
+++ b/gcc/fortran/ChangeLog
@@ -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>
diff --git a/gcc/fortran/module.c b/gcc/fortran/module.c
index c90fe0d..02f5756 100644
--- a/gcc/fortran/module.c
+++ b/gcc/fortran/module.c
@@ -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