Skip to content

Commit 26b7806

Browse files
author
Daniel Hedberg
committed
- Minor update for Visual C++ (get rid of the directory separator in front of the file name).
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@6483 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
1 parent 0de311e commit 26b7806

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

Compiler/runtime/systemimpl.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -430,10 +430,8 @@ RML_BEGIN_LABEL(System__basename)
430430
const char *str = RML_STRINGDATA(rmlA0);
431431
#if defined(__MINGW32__) || defined(_MSC_VER)
432432
const char* res = strrchr(str, '\\');
433-
if (res == NULL) {
434-
res = strrchr(str, '/');
435-
if (res == NULL) { res = str; }
436-
}
433+
if (res == NULL) { res = strrchr(str, '/'); }
434+
if (res == NULL) { res = str; } else { ++res; }
437435
rmlA0 = (void*) mk_scon(res);
438436
#else
439437
char *copy = strdup(str);

0 commit comments

Comments
 (0)