Remove unnecessary config.h includes
[alexxy/gromacs.git] / src / gromacs / fileio / filenm.c
index 45f18226399c94e17e9b4999c84998cd9e8489dc..d8b50e526f3dc98de1ec1ecae7fcade293320616 100644 (file)
@@ -34,9 +34,9 @@
  * To help us fund GROMACS development, we humbly ask that you cite
  * the research papers on the package. Check out http://www.gromacs.org.
  */
-#include "filenm.h"
+#include "gmxpre.h"
 
-#include "config.h"
+#include "filenm.h"
 
 #include <stdio.h>
 #include <string.h>
@@ -561,7 +561,7 @@ int add_suffix_to_output_names(t_filenm *fnm, int nfile, const char *suffix)
                 *extpos = '\0';
                 sprintf(newname, "%s%s.%s", buf, suffix, extpos + 1);
                 sfree(fnm[i].fns[j]);
-                fnm[i].fns[j] = strdup(newname);
+                fnm[i].fns[j] = gmx_strdup(newname);
             }
         }
     }
@@ -579,7 +579,7 @@ t_filenm *dup_tfn(int nf, const t_filenm tfn[])
         ret[i] = tfn[i]; /* just directly copy all non-string fields */
         if (tfn[i].opt)
         {
-            ret[i].opt = strdup(tfn[i].opt);
+            ret[i].opt = gmx_strdup(tfn[i].opt);
         }
         else
         {
@@ -588,7 +588,7 @@ t_filenm *dup_tfn(int nf, const t_filenm tfn[])
 
         if (tfn[i].fn)
         {
-            ret[i].fn = strdup(tfn[i].fn);
+            ret[i].fn = gmx_strdup(tfn[i].fn);
         }
         else
         {
@@ -600,7 +600,7 @@ t_filenm *dup_tfn(int nf, const t_filenm tfn[])
             snew(ret[i].fns, tfn[i].nfiles);
             for (j = 0; j < tfn[i].nfiles; j++)
             {
-                ret[i].fns[j] = strdup(tfn[i].fns[j]);
+                ret[i].fns[j] = gmx_strdup(tfn[i].fns[j]);
             }
         }
     }