*
* Copyright (c) 1991-2000, University of Groningen, The Netherlands.
* Copyright (c) 2001-2004, The GROMACS development team.
- * Copyright (c) 2012,2013,2014,2015,2016, by the GROMACS development team, led by
+ * Copyright (c) 2012,2013,2014,2015,2016,2017, 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.
*/
const char *spec = " !&|";
- return (c != '\0' && std::strchr(spec, c) == NULL);
+ return (c != '\0' && std::strchr(spec, c) == nullptr);
}
static int parse_names(char **string, int *n_names, char **names)
(*string)++;
s = gmx_strdup((*string));
sp = std::strchr(s, c);
- if (sp != NULL)
+ if (sp != nullptr)
{
(*string) += sp-s + 1;
sp[0] = '\0';
{
char buf[STRLEN];
int j, nchain;
- int i, a, natoms, *start = NULL, *end = NULL, ca_start, ca_end;
+ int i, a, natoms, *start = nullptr, *end = nullptr, ca_start, ca_end;
rvec vec;
natoms = atoms->nr;
static gmx_bool check_have_atoms(const t_atoms *atoms, char *string)
{
- if (atoms == NULL)
+ if (atoms == nullptr)
{
printf("Can not process '%s' without atom info, use option -f\n", string);
return FALSE;
}
}
- string = NULL;
+ string = nullptr;
snew(index, natoms);
snew(index1, natoms);
}
printf("\n");
printf("> ");
- if (NULL == fgets(inp_string, STRLEN, stdin))
+ if (nullptr == fgets(inp_string, STRLEN, stdin))
{
gmx_fatal(FARGS, "Error reading user input");
}
t_blocka *block, *block2;
char **gnames, **gnames2;
t_filenm fnm[] = {
- { efSTX, "-f", NULL, ffOPTRD },
- { efNDX, "-n", NULL, ffOPTRDMULT },
- { efNDX, "-o", NULL, ffWRITE }
+ { efSTX, "-f", nullptr, ffOPTRD },
+ { efNDX, "-n", nullptr, ffOPTRDMULT },
+ { efNDX, "-o", nullptr, ffWRITE }
};
#define NFILE asize(fnm)
if (!parse_common_args(&argc, argv, 0, NFILE, fnm, NPA, pa, asize(desc), desc,
- 0, NULL, &oenv))
+ 0, nullptr, &oenv))
{
return 0;
}
fprintf(stderr, "\nReading structure file\n");
read_tps_conf(stxfile, top, &ePBC, &x, &v, box, FALSE);
atoms = &top->atoms;
- if (atoms->pdbinfo == NULL)
+ if (atoms->pdbinfo == nullptr)
{
snew(atoms->pdbinfo, atoms->nr);
}
}
else
{
- atoms = NULL;
- x = NULL;
+ atoms = nullptr;
+ x = nullptr;
}
/* read input file(s) */
block = new_blocka();
- gnames = NULL;
+ gnames = nullptr;
printf("Going to read %d old index file(s)\n", nndxin);
if (nndxin)
{