summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Nocera <hadess@users.sourceforge.net>2003-02-02 12:33:23 +0000
committerBastien Nocera <hadess@users.sourceforge.net>2003-02-02 12:33:23 +0000
commitd2735be904ae6f88cab9cfefc47d809d9582442b (patch)
tree97be373d3fc4f053e55398e850309089abf5e01f
parent788c970df6cdfdf906b951e3de1017d82e2252e6 (diff)
downloadxine-lib-d2735be904ae6f88cab9cfefc47d809d9582442b.tar.gz
xine-lib-d2735be904ae6f88cab9cfefc47d809d9582442b.tar.bz2
- remove LOG from audio_out.c, fix backing up the configfile if there's no configfile to save, and if there's already a backup file
CVS patchset: 4087 CVS date: 2003/02/02 12:33:23
-rw-r--r--src/xine-engine/audio_out.c6
-rw-r--r--src/xine-engine/configfile.c7
2 files changed, 8 insertions, 5 deletions
diff --git a/src/xine-engine/audio_out.c b/src/xine-engine/audio_out.c
index d0b1de0ab..4679c0630 100644
--- a/src/xine-engine/audio_out.c
+++ b/src/xine-engine/audio_out.c
@@ -17,7 +17,7 @@
* along with self program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: audio_out.c,v 1.102 2003/02/01 19:22:30 guenter Exp $
+ * $Id: audio_out.c,v 1.103 2003/02/02 12:33:23 hadess Exp $
*
* 22-8-2001 James imported some useful AC3 sections from the previous alsa driver.
* (c) 2001 Andy Lo A Foe <andy@alsaplayer.org>
@@ -73,9 +73,9 @@
#include "resample.h"
#include "metronom.h"
-
+/*
#define LOG
-
+*/
#define LOG_RESAMPLE_SYNC
#define NUM_AUDIO_BUFFERS 32
diff --git a/src/xine-engine/configfile.c b/src/xine-engine/configfile.c
index 16a774182..50892323a 100644
--- a/src/xine-engine/configfile.c
+++ b/src/xine-engine/configfile.c
@@ -17,7 +17,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: configfile.c,v 1.44 2003/02/01 13:15:22 mroi Exp $
+ * $Id: configfile.c,v 1.45 2003/02/02 12:33:23 hadess Exp $
*
* config object (was: file) management - implementation
*
@@ -719,6 +719,7 @@ void xine_config_save (xine_t *xine, const char *filename) {
FILE *f_config, *f_backup;
sprintf(temp, "%s~", filename);
+ unlink (temp);
if (stat(temp, &backup_stat) != 0) {
char line[1024];
@@ -746,12 +747,14 @@ void xine_config_save (xine_t *xine, const char *filename) {
} else {
if (f_config)
fclose(f_config);
+ else
+ backup = 1;
if (f_backup)
fclose(f_backup);
}
}
- if (!backup) {
+ if (!backup && (stat(filename, &config_stat) == 0)) {
printf("configfile: WARNING: backing up configfile to %s failed\n", temp);
printf("configfile: WARNING: your configuration will not be saved\n");
return;