about summary refs log tree commit diff
path: root/src/libstore/store.cc
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2005-05-04T16·31+0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2005-05-04T16·31+0000
commit5dea0622d1d673bf60f47781c33f343ce9979a7f (patch)
treeb67532d39e3dedae6b0b4a445cc144c9d13a0104 /src/libstore/store.cc
parent4a266e35d4c756af6163a314585e55ecb65a4c0c (diff)
* Idem (constness fix).
* `compare' in GCC 2.95 is broken.

Diffstat (limited to 'src/libstore/store.cc')
-rw-r--r--src/libstore/store.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libstore/store.cc b/src/libstore/store.cc
index d61c3e454705..12045fc35bec 100644
--- a/src/libstore/store.cc
+++ b/src/libstore/store.cc
@@ -63,7 +63,7 @@ static TableId dbSubstitutes = 0;
 static TableId dbDerivers = 0;
 
 
-bool Substitute::operator == (const Substitute & sub)
+bool Substitute::operator == (const Substitute & sub) const
 {
     return program == sub.program
         && args == sub.args;
@@ -170,7 +170,7 @@ void copyPath(const Path & src, const Path & dst)
 bool isInStore(const Path & path)
 {
     return path[0] == '/'
-        && path.compare(0, nixStore.size(), nixStore) == 0
+        && string(path, 0, nixStore.size()) == nixStore
         && path.size() >= nixStore.size() + 2
         && path[nixStore.size()] == '/';
 }