about summary refs log tree commit diff
path: root/src/archive.cc
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2003-10-08T15·06+0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2003-10-08T15·06+0000
commit6baa2c442035fb06652a7fad9d51df1ce41c05f9 (patch)
treec77e57b30ea01fd7ae76ca04a7d8bbc13a1a3979 /src/archive.cc
parentb9f4942bd2f8aae44db6caa5a4ebe5680880fec2 (diff)
* Get rid of identifiers since they are redundant now. This greatly
  simplifies stuff.

* The format of Nix expressions and the database schema changed
  because of this, so it's best to delete old Nix installations.

Diffstat (limited to 'src/archive.cc')
-rw-r--r--src/archive.cc18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/archive.cc b/src/archive.cc
index 4a6211e00eda..9039ad7db43e 100644
--- a/src/archive.cc
+++ b/src/archive.cc
@@ -49,7 +49,7 @@ static void writeString(const string & s, DumpSink & sink)
 static void dump(const string & path, DumpSink & sink);
 
 
-static void dumpEntries(const string & path, DumpSink & sink)
+static void dumpEntries(const Path & path, DumpSink & sink)
 {
     DIR * dir = opendir(path.c_str());
     if (!dir) throw SysError("opening directory " + path);
@@ -82,7 +82,7 @@ static void dumpEntries(const string & path, DumpSink & sink)
 }
 
 
-static void dumpContents(const string & path, unsigned int size, 
+static void dumpContents(const Path & path, unsigned int size, 
     DumpSink & sink)
 {
     writeString("contents", sink);
@@ -110,7 +110,7 @@ static void dumpContents(const string & path, unsigned int size,
 }
 
 
-static void dump(const string & path, DumpSink & sink)
+static void dump(const Path & path, DumpSink & sink)
 {
     struct stat st;
     if (lstat(path.c_str(), &st))
@@ -150,7 +150,7 @@ static void dump(const string & path, DumpSink & sink)
 }
 
 
-void dumpPath(const string & path, DumpSink & sink)
+void dumpPath(const Path & path, DumpSink & sink)
 {
     writeString(archiveVersion1, sink);
     dump(path, sink);
@@ -207,10 +207,10 @@ static void skipGeneric(RestoreSource & source)
 }
 
 
-static void restore(const string & path, RestoreSource & source);
+static void restore(const Path & path, RestoreSource & source);
 
 
-static void restoreEntry(const string & path, RestoreSource & source)
+static void restoreEntry(const Path & path, RestoreSource & source)
 {
     string s, name;
 
@@ -235,7 +235,7 @@ static void restoreEntry(const string & path, RestoreSource & source)
 }
 
 
-static void restoreContents(int fd, const string & path, RestoreSource & source)
+static void restoreContents(int fd, const Path & path, RestoreSource & source)
 {
     unsigned int size = readInt(source);
     unsigned int left = size;
@@ -254,7 +254,7 @@ static void restoreContents(int fd, const string & path, RestoreSource & source)
 }
 
 
-static void restore(const string & path, RestoreSource & source)
+static void restore(const Path & path, RestoreSource & source)
 {
     string s;
 
@@ -331,7 +331,7 @@ static void restore(const string & path, RestoreSource & source)
 }
 
 
-void restorePath(const string & path, RestoreSource & source)
+void restorePath(const Path & path, RestoreSource & source)
 {
     if (readString(source) != archiveVersion1)
         throw badArchive("expected Nix archive");