]> git.alsa-project.org Git - alsa-utils.git/commitdiff
alsactl - More explicit open error message
authorTakashi Iwai <tiwai@suse.de>
Wed, 23 May 2007 10:03:29 +0000 (12:03 +0200)
committerTakashi Iwai <tiwai@suse.de>
Wed, 23 May 2007 10:03:29 +0000 (12:03 +0200)
Include more explicit error message when open config file in write
mode (this is for the "names" command)

From: Tomas Pospisek <tpo2@sourcepole.ch>

alsactl/names.c

index f158b92c5988e344d9308e9b070747a49793a1b1..ba10770a874a71d79afe3aa69da291370e9035a4 100644 (file)
@@ -535,7 +535,7 @@ int generate_names(const char *cfgfile)
                        err = snd_output_stdio_open(&out, cfgfile, "w+");
                }
                if (err < 0) {
-                       error("Cannot open %s for writing", cfgfile);
+                       error("Cannot open %s for writing: %s", cfgfile, snd_strerror(err));
                        return -errno;
                }
                err = snd_config_save(config, out);