summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErik Troan <ewt@src.gnome.org>1997-07-07 22:22:51 +0000
committerErik Troan <ewt@src.gnome.org>1997-07-07 22:22:51 +0000
commite23459d6b908207705df046dd0067d1976be3532 (patch)
treebf3e24db694b35b4e34deee3f56c61b8bb92c112
parent764bc655a1ddec893730a187add4c72f7c736847 (diff)
downloadgnome-common-e23459d6b908207705df046dd0067d1976be3532.tar.gz
1) changed popt's ternary operator to work properlyr2-4-9r2-4-8r2-4-7r2-4-6r2-4-5r2-4-4r2-4-3r1-0
2) popt doesn't take \ at the end of a line as a newline 3) fixed --scripts in rpmpopt to take advantage of #1 svn path=/trunk/; revision=28
-rw-r--r--support/popt.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/support/popt.c b/support/popt.c
index bc24b9b..d4dee02 100644
--- a/support/popt.c
+++ b/support/popt.c
@@ -451,7 +451,8 @@ int poptReadConfigFile(poptContext con, char * fn) {
*dst++ = *chptr++;
if (chptr < end) {
if (*chptr == '\n')
- *(dst - 1) = *chptr++;
+ dst--, chptr++;
+ /* \ at the end of a line does not insert a \n */
else
*dst++ = *chptr++;
}