From 7818b5ecb0a83126374896d7e678ca8aff9a1599 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Fri, 6 Jul 2012 23:47:38 +0300 Subject: [PATCH] Add Path::c_str() method --- source/fs/path.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/source/fs/path.h b/source/fs/path.h index 210b5d9..5d0a5d3 100644 --- a/source/fs/path.h +++ b/source/fs/path.h @@ -68,6 +68,9 @@ public: /// Returns the path as a string. const std::string &str() const { return path; } + /// Returns the path as a pointer to a null-terminated string. + const char *c_str() const { return path.c_str(); } + /// Returns the number of components in the path. unsigned size() const; -- 2.43.0