summaryrefslogtreecommitdiff
path: root/recordmydesktop/src
diff options
context:
space:
mode:
Diffstat (limited to 'recordmydesktop/src')
-rw-r--r--recordmydesktop/src/rmd_cache.c14
-rw-r--r--recordmydesktop/src/specsfile.c66
2 files changed, 80 insertions, 0 deletions
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);
+ }
}
diff --git a/recordmydesktop/src/specsfile.c b/recordmydesktop/src/specsfile.c
index cb6e554..09c0f25 100644
--- a/recordmydesktop/src/specsfile.c
+++ b/recordmydesktop/src/specsfile.c
@@ -24,8 +24,74 @@
* For further information contact me at johnvarouhakis@gmail.com *
******************************************************************************/
+#include <stdlib.h>
+#include <stdio.h>
#include <rmdtypes.h>
+int WriteStrOpt(FILE *fp,char *desc,char delim,char *val){
+
+
+
+}
+
+int WriteIntOpt(FILE *fp,char *desc,char delim,int val){
+
+
+
+}
+
+int WriteFloatOpt(FILE *fp,char *desc,char delim,int val){
+
+
+
+}
+
+
+char *ReadStrOpt(FILE *fp,char delim){
+
+
+}
+
+int ReadIntOpt(FILE *fp,char delim){
+
+
+}
+
+float ReadFloatOpt(FILE *fp,char delim){
+
+
+}
+
+
+int WriteSpecsFile(ProgData *pdata){
+
+ FILE *fp;
+
+
+ fp=fopen(pdata->cache_data->specsfile,"wb");
+ if(fp==NULL)
+ return 1;
+
+
+
+ fclose(fp);
+ return 0;
+
+}
+
+int ReadSpecsFile(ProgData *pdata){
+
+
+
+
+
+}
+
+
+
+
+
+
© All Rights Reserved