*
* Copyright (c) 1991-2000, University of Groningen, The Netherlands.
* Copyright (c) 2001-2004, The GROMACS development team.
- * Copyright (c) 2013,2014,2015, by the GROMACS development team, led by
+ * Copyright (c) 2013,2014,2015,2016, by the GROMACS development team, led by
* Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
* and including many others, as listed in the AUTHORS file in the
* top-level source directory and at http://www.gromacs.org.
#define IS_SET(fn) ((fn.flag &ffSET) != 0)
#define IS_OPT(fn) ((fn.flag &ffOPT) != 0)
+const t_filenm *getFilenm(const char *opt, int nfile, const t_filenm fnm[])
+{
+ int i;
+
+ for (i = 0; (i < nfile); i++)
+ {
+ if (strcmp(opt, fnm[i].opt) == 0)
+ {
+ return &fnm[i];
+ }
+ }
+
+ return NULL;
+}
+
const char *opt2fn(const char *opt, int nfile, const t_filenm fnm[])
{
int i;