diff options
Diffstat (limited to 'apps/plugins')
| -rw-r--r-- | apps/plugins/calendar.c | 4 | ||||
| -rw-r--r-- | apps/plugins/clock.c | 2 | ||||
| -rw-r--r-- | apps/plugins/iriverify.c | 2 | ||||
| -rw-r--r-- | apps/plugins/lib/bmp.c | 2 | ||||
| -rw-r--r-- | apps/plugins/lib/configfile.c | 2 | ||||
| -rw-r--r-- | apps/plugins/search.c | 2 | ||||
| -rw-r--r-- | apps/plugins/sort.c | 2 | ||||
| -rw-r--r-- | apps/plugins/test_disk.c | 4 | ||||
| -rw-r--r-- | apps/plugins/vbrfix.c | 2 | ||||
| -rw-r--r-- | apps/plugins/viewer.c | 6 | ||||
| -rw-r--r-- | apps/plugins/vu_meter.c | 2 | ||||
| -rw-r--r-- | apps/plugins/wav2wv.c | 2 | ||||
| -rw-r--r-- | apps/plugins/zxbox/snapshot.c | 2 |
13 files changed, 17 insertions, 17 deletions
diff --git a/apps/plugins/calendar.c b/apps/plugins/calendar.c index a57cade..34af474 100644 --- a/apps/plugins/calendar.c +++ b/apps/plugins/calendar.c @@ -316,7 +316,7 @@ static bool save_memo(int changed, bool new_mod, struct shown *shown) { int fp,fq; fp = rb->open("/.rockbox/.memo",O_RDONLY | O_CREAT); - fq = rb->creat("/.rockbox/~temp", O_WRONLY); + fq = rb->creat("/.rockbox/~temp"); if ( (fq != -1) && (fp != -1) ) { int i; @@ -345,7 +345,7 @@ static bool save_memo(int changed, bool new_mod, struct shown *shown) rb->write(fq,temp,1); } rb->close(fp); - fp = rb->creat("/.rockbox/.memo", O_WRONLY); + fp = rb->creat("/.rockbox/.memo"); rb->lseek(fp, 0, SEEK_SET); rb->lseek(fq, 0, SEEK_SET); for (i = 0; i < rb->filesize(fq); i++) diff --git a/apps/plugins/clock.c b/apps/plugins/clock.c index 28cd223..19c7dac 100644 --- a/apps/plugins/clock.c +++ b/apps/plugins/clock.c @@ -903,7 +903,7 @@ void save_settings(bool interface) rb->lcd_update(); } - fd = rb->creat(default_filename, O_WRONLY); /* create the settings file */ + fd = rb->creat(default_filename); /* create the settings file */ if(fd >= 0) /* file exists, save successful */ { diff --git a/apps/plugins/iriverify.c b/apps/plugins/iriverify.c index 47cb385..555c920 100644 --- a/apps/plugins/iriverify.c +++ b/apps/plugins/iriverify.c @@ -67,7 +67,7 @@ static int write_file(void) rb->snprintf(tmpfilename, MAX_PATH+1, "%s.tmp", filename); - fd = rb->creat(tmpfilename, O_WRONLY); + fd = rb->creat(tmpfilename); if(fd < 0) return 10 * fd - 1; diff --git a/apps/plugins/lib/bmp.c b/apps/plugins/lib/bmp.c index 18968af..dc8432f 100644 --- a/apps/plugins/lib/bmp.c +++ b/apps/plugins/lib/bmp.c @@ -56,7 +56,7 @@ int save_bmp_file( char* filename, struct bitmap *bm, struct plugin_api* rb ) int fh; int x,y; if( bm->format != FORMAT_NATIVE ) return -1; - fh = rb->PREFIX(creat)( filename, O_WRONLY ); + fh = rb->creat( filename ); if( fh < 0 ) return -1; rb->write( fh, header, sizeof( header ) ); diff --git a/apps/plugins/lib/configfile.c b/apps/plugins/lib/configfile.c index d5b60bc..3ca3805 100644 --- a/apps/plugins/lib/configfile.c +++ b/apps/plugins/lib/configfile.c @@ -34,7 +34,7 @@ int configfile_save(const char *filename, struct configdata *cfg, char buf[MAX_PATH]; cfg_rb->snprintf(buf, MAX_PATH, "/.rockbox/rocks/%s", filename); - fd = cfg_rb->creat(buf, O_WRONLY); + fd = cfg_rb->creat(buf); if(fd < 0) return fd*10 - 1; diff --git a/apps/plugins/search.c b/apps/plugins/search.c index c174abf..5a30ce6 100644 --- a/apps/plugins/search.c +++ b/apps/plugins/search.c @@ -126,7 +126,7 @@ static bool search_init(char* file) if (fd==-1) return false; - fdw = rb->creat(resultfile, O_WRONLY); + fdw = rb->creat(resultfile); if (fdw < 0) { #ifdef HAVE_LCD_BITMAP diff --git a/apps/plugins/sort.c b/apps/plugins/sort.c index 77342f3..80ef22f 100644 --- a/apps/plugins/sort.c +++ b/apps/plugins/sort.c @@ -140,7 +140,7 @@ static int write_file(void) /* Create a temporary file */ rb->snprintf(tmpfilename, MAX_PATH+1, "%s.tmp", filename); - fd = rb->creat(tmpfilename, O_WRONLY); + fd = rb->creat(tmpfilename); if(fd < 0) return 10 * fd - 1; diff --git a/apps/plugins/test_disk.c b/apps/plugins/test_disk.c index 3292cfa..edc1dfb 100644 --- a/apps/plugins/test_disk.c +++ b/apps/plugins/test_disk.c @@ -102,7 +102,7 @@ static bool test_fs(void) rb->snprintf(text_buf, sizeof text_buf, "FS stress test: %dKB", (TEST_SIZE>>10)); log_lcd(text_buf, true); - fd = rb->creat(TEST_FILE, 0); + fd = rb->creat(TEST_FILE); if (fd < 0) { rb->splash(0, true, "Couldn't create testfile."); @@ -193,7 +193,7 @@ static bool test_speed(void) log_init(); log_lcd("Disk speed test", true); - fd = rb->creat(TEST_FILE, 0); + fd = rb->creat(TEST_FILE); if (fd < 0) { rb->splash(0, true, "Couldn't create testfile."); diff --git a/apps/plugins/vbrfix.c b/apps/plugins/vbrfix.c index d05419f..9bdaf49 100644 --- a/apps/plugins/vbrfix.c +++ b/apps/plugins/vbrfix.c @@ -50,7 +50,7 @@ static int insert_data_in_file(char *fname, int fpos, char *buf, int num_bytes) return 10*orig_fd - 1; } - fd = rb->creat(tmpname, O_WRONLY); + fd = rb->creat(tmpname); if(fd < 0) { rb->close(orig_fd); return 10*fd - 2; diff --git a/apps/plugins/viewer.c b/apps/plugins/viewer.c index a8ef5eb..8590283 100644 --- a/apps/plugins/viewer.c +++ b/apps/plugins/viewer.c @@ -1074,7 +1074,7 @@ static void viewer_load_settings(void) /* same name as global, but not the same if (i < data->bookmarked_files_count) { /* it is in the list, write everything back in the correct order, and reload the file correctly */ - settings_fd = rb->creat(BOOKMARKS_FILE, O_WRONLY); + settings_fd = rb->creat(BOOKMARKS_FILE); if (settings_fd >=0 ) { if (data->bookmarked_files_count > MAX_BOOKMARKED_FILES) @@ -1092,7 +1092,7 @@ static void viewer_load_settings(void) /* same name as global, but not the same } else /* not in list, write the list to the file */ { - settings_fd = rb->creat(BOOKMARKS_FILE, O_WRONLY); + settings_fd = rb->creat(BOOKMARKS_FILE); if (settings_fd >=0 ) { if (++(data->bookmarked_files_count) > MAX_BOOKMARKED_FILES) @@ -1120,7 +1120,7 @@ static void viewer_load_settings(void) /* same name as global, but not the same static void viewer_save_settings(void)/* same name as global, but not the same file.. */ { int settings_fd; - settings_fd = rb->creat(SETTINGS_FILE, O_WRONLY); /* create the settings file */ + settings_fd = rb->creat(SETTINGS_FILE); /* create the settings file */ rb->write (settings_fd, &prefs, sizeof(struct preferences)); rb->close(settings_fd); diff --git a/apps/plugins/vu_meter.c b/apps/plugins/vu_meter.c index cbfc0ee..4a68088 100644 --- a/apps/plugins/vu_meter.c +++ b/apps/plugins/vu_meter.c @@ -335,7 +335,7 @@ void load_settings(void) { } void save_settings(void) { - int fp = rb->creat("/.rockbox/rocks/.vu_meter", O_WRONLY); + int fp = rb->creat("/.rockbox/rocks/.vu_meter"); if(fp >= 0) { rb->write (fp, &settings, sizeof(struct saved_settings)); rb->close(fp); diff --git a/apps/plugins/wav2wv.c b/apps/plugins/wav2wv.c index 5b71e7e..2e2076c 100644 --- a/apps/plugins/wav2wv.c +++ b/apps/plugins/wav2wv.c @@ -174,7 +174,7 @@ static int wav2wv (char *filename) extension [1] = extension [2]; extension [2] = 0; - out_fd = rb->creat (filename, O_WRONLY); + out_fd = rb->creat (filename); extension [2] = extension [1]; extension [1] = save_a; diff --git a/apps/plugins/zxbox/snapshot.c b/apps/plugins/zxbox/snapshot.c index c67b7a8..d89e533 100644 --- a/apps/plugins/zxbox/snapshot.c +++ b/apps/plugins/zxbox/snapshot.c @@ -586,7 +586,7 @@ static void save_snapshot_file_type(char *name, int type) int snsh; snsh = rb->open(name, O_WRONLY); if(snsh < 0) { - snsh = rb->creat(name, O_WRONLY); + snsh = rb->creat(name); if(snsh < 0) { put_msg("Could not create snapshot file"); return; |