xmlutil.cpp:use rename instead of cp

Origin commit data
------------------
Branch: ni/coolstream
Commit: aa2f00bcea
Author: Jacek Jendrzej <overx300@gmail.com>
Date: 2012-05-03 (Thu, 03 May 2012)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
Jacek Jendrzej
2012-05-03 19:49:54 +02:00
parent dddc764e7a
commit ae3c8fdb49

View File

@@ -421,12 +421,12 @@ static void write_indexxml_footer(FILE *fd)
fprintf(fd, "</dvbepgfiles>\n");
}
void cp(char * from, char * to)
{
char cmd[256];
snprintf(cmd, 256, "cp -f %s %s", from, to);
system(cmd);
}
// void cp(char * from, char * to)
// {
// char cmd[256];
// snprintf(cmd, 256, "cp -f %s %s", from, to);
// system(cmd);
// }
void writeEventsToFile(char *epgdir)
{
@@ -484,7 +484,7 @@ _done:
sprintf(filename, "%s/index.xml", epgdir);
cp(tmpname, filename);
rename(tmpname, filename);
unlink(tmpname);
return ;