From 07b939c6fac09078370634df7c06e3b1babf486b Mon Sep 17 00:00:00 2001 From: David Robillard Date: Mon, 7 Nov 2011 20:29:22 +0000 Subject: Remove use of non-portable _XOPEN_SOURCE and strdup. git-svn-id: http://svn.drobilla.net/lad/trunk/patchage@3604 a436a847-0d15-0410-975c-d299462d15a1 --- src/PatchageEvent.cpp | 4 ++-- src/PatchageEvent.hpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/PatchageEvent.cpp b/src/PatchageEvent.cpp index 623b566..e9507bc 100644 --- a/src/PatchageEvent.cpp +++ b/src/PatchageEvent.cpp @@ -43,12 +43,12 @@ PatchageEvent::execute(Patchage* patchage) } else if (_type == CLIENT_CREATION) { // No empty modules (for now) - free(_str); + g_free(_str); _str = NULL; } else if (_type == CLIENT_DESTRUCTION) { patchage->canvas()->remove_module(_str); - free(_str); + g_free(_str); _str = NULL; } else if (_type == PORT_CREATION) { diff --git a/src/PatchageEvent.hpp b/src/PatchageEvent.hpp index 2f97eec..1b13a94 100644 --- a/src/PatchageEvent.hpp +++ b/src/PatchageEvent.hpp @@ -55,7 +55,7 @@ public: {} PatchageEvent(Type type, const char* str) - : _str(strdup(str)) + : _str(g_strdup(str)) , _type(type) {} -- cgit v1.2.1