Skip to content
Permalink
Browse files
8252704: Absolute library paths are not properly quoted
Reviewed-by: sundar
  • Loading branch information
JornVernee committed Sep 2, 2020
1 parent 1dc9149 commit eb0768aae2928e0c869220e96e3fb2ad41c294ad
Showing with 5 additions and 1 deletion.
  1. +5 −1 src/jdk.incubator.jextract/share/classes/jdk/internal/jextract/impl/SourceConstantHelper.java
@@ -634,12 +634,16 @@ private void emitLibraries(String[] libraryNames) {
for (String lib : libraryNames) {
indent();
append('\"');
append(lib);
append(quoteLibraryName(lib));
append("\",\n");
}
decrAlign();
indent();
append("});\n\n");
decrAlign();
}

private static String quoteLibraryName(String lib) {
return lib.replace("\\", "\\\\"); // double up slashes
}
}

0 comments on commit eb0768a

Please sign in to comment.