From d5a5a83ad4fb8aba3b334039f567267a0463ee5a Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Thu, 9 Feb 2012 18:27:45 +0100 Subject: Use data() instead of c_str() where appropriate --- src/libstore/gc.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/libstore/gc.cc') diff --git a/src/libstore/gc.cc b/src/libstore/gc.cc index 14c8ba0bfe..c2e999a6e6 100644 --- a/src/libstore/gc.cc +++ b/src/libstore/gc.cc @@ -196,7 +196,7 @@ void LocalStore::addTempRoot(const Path & path) lockFile(fdTempRoots, ltWrite, true); string s = path + '\0'; - writeFull(fdTempRoots, (const unsigned char *) s.c_str(), s.size()); + writeFull(fdTempRoots, (const unsigned char *) s.data(), s.size()); /* Downgrade to a read lock. */ debug(format("downgrading to read lock on `%1%'") % fnTempRoots); -- cgit 1.4.1