src/driver/record.cpp: -fix auto_delete

This commit is contained in:
satbaby
2012-11-04 13:25:44 +01:00
parent 01d44a6272
commit 9cec234d73

View File

@@ -231,8 +231,8 @@ bool CRecordInstance::Stop(bool remove_event)
CCamManager::getInstance()->Stop(channel_id, CCamManager::RECORD); CCamManager::getInstance()->Stop(channel_id, CCamManager::RECORD);
if((autoshift && g_settings.auto_delete) /* || autoshift_delete*/) { if((autoshift && g_settings.auto_delete) /* || autoshift_delete*/) {
snprintf(buf,sizeof(buf), "\"%s.ts\"", filename); snprintf(buf,sizeof(buf), "nice -n 20 rm -f \"%s.ts\" &", filename);
my_system("nice", "-n20", "rm", "-f", buf); my_system("/bin/sh", "-c", buf);
snprintf(buf,sizeof(buf), "%s.xml", filename); snprintf(buf,sizeof(buf), "%s.xml", filename);
//autoshift_delete = false; //autoshift_delete = false;
unlink(buf); unlink(buf);