summaryrefslogtreecommitdiff
path: root/apt-pkg
diff options
context:
space:
mode:
authorDavid Kalnischkies <kalnischkies@gmail.com>2009-09-07 14:59:19 +0200
committerDavid Kalnischkies <kalnischkies@gmail.com>2009-09-07 14:59:19 +0200
commitc914647fb05653878a14ae391f52b5e94cc73b26 (patch)
tree8d6d0564c495bd85f6ef312e700f4adfcaf1a7d6 /apt-pkg
parent50c409c42a971c6e8a25cb32a87992474247834b (diff)
reintroduce #clear and #include in the config files,
they there broken since 0.7.21 with the introduction of #-comments
Diffstat (limited to 'apt-pkg')
-rw-r--r--apt-pkg/contrib/configuration.cc8
1 files changed, 5 insertions, 3 deletions
diff --git a/apt-pkg/contrib/configuration.cc b/apt-pkg/contrib/configuration.cc
index b83ece3e4..4e8586e83 100644
--- a/apt-pkg/contrib/configuration.cc
+++ b/apt-pkg/contrib/configuration.cc
@@ -601,9 +601,11 @@ bool ReadConfigFile(Configuration &Conf,const string &FName,bool AsSectional,
InQuote = !InQuote;
if (InQuote == true)
continue;
-
- if ((*I == '/' && I + 1 != End && I[1] == '/') || *I == '#')
- {
+
+ if ((*I == '/' && I + 1 != End && I[1] == '/') ||
+ (*I == '#' && strcmp(string(I,I+6).c_str(),"#clear") != 0 &&
+ strcmp(string(I,I+8).c_str(),"#include") != 0))
+ {
End = I;
break;
}