From 4d50ee63d6eebe73579f05214e6a0fc1b8ebad99 Mon Sep 17 00:00:00 2001 From: Magnus Ihse Bursie Date: Tue, 20 Feb 2024 22:24:25 +0000 Subject: [PATCH] 8326368: compare.sh -2bins prints ugly errors on Windows Reviewed-by: erikj --- make/scripts/compare.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/make/scripts/compare.sh b/make/scripts/compare.sh index a395e0cd850..395a0c7bdf8 100644 --- a/make/scripts/compare.sh +++ b/make/scripts/compare.sh @@ -1,6 +1,6 @@ #!/bin/bash # -# Copyright (c) 2012, 2022, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2012, 2024, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -699,14 +699,16 @@ compare_bin_file() { unset _NT_SYMBOL_PATH if [ "$(uname -o)" = "Cygwin" ]; then THIS=$(cygpath -msa $THIS) - OTHER=$(cygpath -msa $OTHER) + if [ -n "$OTHER" ]; then + OTHER=$(cygpath -msa $OTHER) + fi fi # Build an _NT_SYMBOL_PATH that contains all known locations for # pdb files. PDB_DIRS="$(ls -d \ {$OTHER,$THIS}/support/modules_{cmds,libs}/{*,*/*} \ {$OTHER,$THIS}/support/native/jdk.jpackage/* \ - )" + 2> /dev/null )" export _NT_SYMBOL_PATH="$(echo $PDB_DIRS | tr ' ' ';')" fi