/*
- * Copyright (c) 2001-2004 The Regents of The University of Michigan
+ * Copyright (c) 2001-2005 The Regents of The University of Michigan
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
tmpf.close();
- char *cfile = strcpy(new char[file.size() + 1], file.c_str());
+ char *cfile = strncpy(new char[file.size() + 1], file.c_str(),
+ file.size());
char *dir = dirname(cfile);
char *dir_arg = NULL;
if (*dir != '.') {
arg += dir;
dir_arg = new char[arg.size() + 1];
- strcpy(dir_arg, arg.c_str());
+ strncpy(dir_arg, arg.c_str(), arg.size());
}
delete [] cfile;