DPF

DISTRHO Plugin Framework
Log | Files | Refs | Submodules | README | LICENSE

commit 1ae79e9a5303ec6873ecc26a0834d5a1017ecee6
parent 7066dd1b544f5319526580bde682f6df0d99ac80
Author: JP Cimalando <jp-dev@inbox.ru>
Date:   Tue, 30 Jul 2019 18:35:31 +0200

sofd: skip strcpy in case of same source and destination

Diffstat:
Mdgl/src/sofd/libsofd.c | 3++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/dgl/src/sofd/libsofd.c b/dgl/src/sofd/libsofd.c @@ -1257,7 +1257,8 @@ static int fib_opendir (Display *dpy, const char* path, const char *sel) { } else { int i; struct dirent *de; - strcpy (_cur_path, path); + if (path != _cur_path) + strcpy (_cur_path, path); if (_cur_path[strlen (_cur_path) -1] != '/') strcat (_cur_path, "/");