diff options
author | Romain Forlot <romain.forlot@iot.bzh> | 2017-09-25 18:20:36 +0200 |
---|---|---|
committer | Romain Forlot <romain.forlot@iot.bzh> | 2017-12-14 11:00:25 +0100 |
commit | fb1d083aa2702b96ff33ab7f3249ef9b1ed5a715 (patch) | |
tree | 486115d5a551c94ec24a21f06cc05e0fdbaff20f /signal-composer-binding | |
parent | c80c2b1919a0b5cc8c67a3fcd257e965da465315 (diff) |
Use C++ string instead of C classic char
Change-Id: I739a68e98623da4a6962c2d91025e4c0bfc222e1
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
Diffstat (limited to 'signal-composer-binding')
-rw-r--r-- | signal-composer-binding/signal-composer-binding.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/signal-composer-binding/signal-composer-binding.cpp b/signal-composer-binding/signal-composer-binding.cpp index 44b644c..cc3b9a8 100644 --- a/signal-composer-binding/signal-composer-binding.cpp +++ b/signal-composer-binding/signal-composer-binding.cpp @@ -197,11 +197,11 @@ void get(struct afb_req request) int loadConf() { int err = 0; - const char* rootdir = strncat(GetBindingDirPath(), "/etc", - sizeof(GetBindingDirPath()) - strlen(GetBindingDirPath()) -1); + std::string bindingDirPath = GetBindingDirPath(); + std::string rootdir = bindingDirPath + "/etc"; Composer& composer = Composer::instance(); - err = composer.loadConfig(rootdir); + err = composer.loadConfig(rootdir.c_str()); return err; } |