From 5ffa6a940a50c5405dcbb0cbc13177cedbdef5c5 Mon Sep 17 00:00:00 2001 From: iovar Date: Tue, 20 Nov 2007 17:51:10 +0000 Subject: specsfile.c: added some stubs rmd_cache.c: added specsfile creation in initCache... git-svn-id: https://recordmydesktop.svn.sourceforge.net/svnroot/recordmydesktop/trunk@436 f606c939-3180-4ac9-a4b8-4b8779d57d0a --- recordmydesktop/src/rmd_cache.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'recordmydesktop/src/rmd_cache.c') diff --git a/recordmydesktop/src/rmd_cache.c b/recordmydesktop/src/rmd_cache.c index 8a0894e..b8bfe3a 100644 --- a/recordmydesktop/src/rmd_cache.c +++ b/recordmydesktop/src/rmd_cache.c @@ -93,6 +93,11 @@ int PurgeCache(CacheData *cache_data_t,int sound){ exit_value=1; } } + if(remove(cache_data_t->specsfile)){ + fprintf(stderr,"Couldn't remove temporary file %s", + cache_data_t->specsfile); + exit_value=1; + } if(remove(cache_data_t->projname)){ fprintf(stderr,"Couldn't remove temporary directory %s", cache_data_t->projname); @@ -154,6 +159,10 @@ void InitCacheData(ProgData *pdata, cache_data_t->audiodata=malloc(strlen(cache_data_t->projname)+10); strcpy(cache_data_t->audiodata,cache_data_t->projname); strcat(cache_data_t->audiodata,"audio.pcm"); + //specsfile + cache_data_t->specsfile=malloc(strlen(cache_data_t->projname)+10); + strcpy(cache_data_t->specsfile,cache_data_t->projname); + strcat(cache_data_t->specsfile,"specs.txt"); //now that've got out buffers and our filenames we start //creating the needed files @@ -187,6 +196,11 @@ void InitCacheData(ProgData *pdata, exit(13); } } + if(WriteSpecsFile(pdata)){ + fprintf(stderr,"Could not write specsfile %s !!!\n", + cache_data_t->specsfile); + exit(13); + } } -- cgit v1.2.3