about summary refs log tree commit diff
path: root/src/libutil/serialise.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/libutil/serialise.cc')
-rw-r--r--src/libutil/serialise.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libutil/serialise.cc b/src/libutil/serialise.cc
index c4563ffd1212..9270806a7798 100644
--- a/src/libutil/serialise.cc
+++ b/src/libutil/serialise.cc
@@ -159,7 +159,7 @@ void writeString(const unsigned char * buf, size_t len, Sink & sink)
 
 void writeString(const string & s, Sink & sink)
 {
-    writeString((const unsigned char *) s.c_str(), s.size(), sink);
+    writeString((const unsigned char *) s.data(), s.size(), sink);
 }