#include "network.h"
#include "gromacs/topology/symtab.h"
+#include "gromacs/utility/cstringutil.h"
#include "gromacs/utility/fatalerror.h"
#include "gromacs/utility/smalloc.h"
{
atoms2->atom[a2] = atoms1->atom[a1];
snew(atoms2->atomname[a2], 1);
- *atoms2->atomname[a2] = strdup(*atoms1->atomname[a1]);
+ *atoms2->atomname[a2] = gmx_strdup(*atoms1->atomname[a1]);
}
static atom_id pdbasearch_atom(const char *name, int resind, t_atoms *pdba,
{
if (hb[rnr].name == NULL)
{
- hb[rnr].name = strdup(ahptr->name);
+ hb[rnr].name = gmx_strdup(ahptr->name);
}
merge_hacks(ahptr, &hb[rnr]);
}
{
if ( (*abi)[*nabi + k].oname == NULL)
{
- (*abi)[*nabi + k].nname = strdup(atomname);
+ (*abi)[*nabi + k].nname = gmx_strdup(atomname);
(*abi)[*nabi + k].nname[0] = 'H';
}
}
(*abi)[*nabi + k].oname ? (*abi)[*nabi + k].oname : "");
}
sfree((*abi)[*nabi + k].nname);
- (*abi)[*nabi + k].nname = strdup(hbr->hack[j].nname);
+ (*abi)[*nabi + k].nname = gmx_strdup(hbr->hack[j].nname);
}
if (hbr->hack[j].tp == 10 && k == 2)
ab[i][j].nname);
}
snew(newpdba->atomname[newi], 1);
- *newpdba->atomname[newi] = strdup(ab[i][j].nname);
+ *newpdba->atomname[newi] = gmx_strdup(ab[i][j].nname);
if (ab[i][j].oname != NULL && ab[i][j].atom) /* replace */
{ /* newpdba->atom[newi].m = ab[i][j].atom->m; */
/* newpdba->atom[newi].q = ab[i][j].atom->q; */