From e0813bfbe82cf9b1c111db652ae8de07aa33728c Mon Sep 17 00:00:00 2001 From: grossmj Date: Fri, 23 Nov 2018 18:47:42 +0700 Subject: [PATCH] Normalize symbol ID on Windows. --- gns3server/controller/symbols.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gns3server/controller/symbols.py b/gns3server/controller/symbols.py index 671a9fbc..ab59d27d 100644 --- a/gns3server/controller/symbols.py +++ b/gns3server/controller/symbols.py @@ -66,7 +66,7 @@ class Symbols: for filename in files: if filename.startswith('.'): continue - symbol_file = posixpath.normpath(os.path.relpath(os.path.join(root, filename), get_resource("symbols"))) + symbol_file = posixpath.normpath(os.path.relpath(os.path.join(root, filename), get_resource("symbols"))).replace('\\', '/') symbol_id = ':/symbols/' + symbol_file symbols.append({'symbol_id': symbol_id, 'filename': symbol_file, @@ -79,7 +79,7 @@ class Symbols: for filename in files: if filename.startswith('.'): continue - symbol_file = posixpath.normpath(os.path.relpath(os.path.join(root, filename), directory)) + symbol_file = posixpath.normpath(os.path.relpath(os.path.join(root, filename), directory)).replace('\\', '/') symbols.append({'symbol_id': symbol_file, 'filename': symbol_file, 'builtin': False,})