]> code.delx.au - spectrwm/commitdiff
Fix fparseln flags to remove escape characters in the result.
authorReginald Kennedy <rk@rejii.com>
Thu, 1 Nov 2012 17:26:30 +0000 (01:26 +0800)
committerReginald Kennedy <rk@rejii.com>
Thu, 1 Nov 2012 18:31:34 +0000 (02:31 +0800)
For example, \# should result in #.

Add note in manpage that # must be escaped when not used in an option.

spectrwm.1
spectrwm.c

index 38c208ecbd87402931ea466e2b60c37197784714..b90227b23d22892634b4c17fd1a1e0e27c31e547 100644 (file)
@@ -82,6 +82,9 @@ Colors need to be specified per the
 .Xr XQueryColor 3
 specification.
 .Pp
+Comments begin with a #.  When a literal '#' is desired in an option, then it
+must be escaped with a backslash. i.e. \e#
+.Pp
 The file supports the following keywords:
 .Bl -tag -width 2m
 .It Ic autorun
@@ -427,6 +430,9 @@ is the desired program, and
 .Aq arg
 is zero or more arguments to the program.
 .Pp
+Remember that when using # in your program call, it must be escaped with a
+backslash. i.e. \e#
+.Pp
 The following argument variables will be substituted for values at the time the program
 is spawned:
 .Pp
index 16cb8b397f01c4284230ed27a87d59acb23e2b1c..4530bd71de3db02335b771b9388dfe2359af6247 100644 (file)
@@ -7246,8 +7246,8 @@ conf_load(const char *filename, int keymapping)
                if (line)
                        free(line);
 
-               if ((line = fparseln(config, &linelen, &lineno, NULL, 0))
-                   == NULL) {
+               if ((line = fparseln(config, &linelen, &lineno, NULL,
+                   FPARSELN_UNESCCOMM | FPARSELN_UNESCCONT)) == NULL) {
                        if (ferror(config))
                                err(1, "%s", filename);
                        else