kriegaex commented on code in PR #129:
URL: https://github.com/apache/xalan-java/pull/129#discussion_r1407046638


##########
serializer/src/main/java/org/apache/xml/serializer/Version.java:
##########
@@ -55,7 +55,16 @@ public final class Version
 
   private static void readProperties() {
     Properties pomProperties = new Properties();
-    try (InputStream fromResource = 
Version.class.getClassLoader().getResourceAsStream(POM_PROPERTIES_PATH)) {
+    ClassLoader classLoader = Version.class.getClassLoader();
+    if (classLoader == null) {
+      // Oops! Someone put Xalan is on the bootstrap class loader (BCL) -> fall
+      // back to the system class loader, because there is no Classloader
+      // instance for the BCL (native code). Due to class loader hierarchy,
+      // however, the resource will also be found when asking for it from a
+      // level below the BCL.
+      classLoader = ClassLoader.getSystemClassLoader();
+    }
+    try (InputStream fromResource = 
classLoader.getResourceAsStream(POM_PROPERTIES_PATH)) {

Review Comment:
   Good for you to know how I would "definitely" react to a meaningful code 
review.
   
   Stop obsessing about tests in a project which does not have any tests. I 
explained in excruciating detail already that I am all in for tests, if they 
are part of the project, and why that is a separate (huge) PR. I also explained 
that I will not create shadow branches in the xalan-test repository. We would 
need one for the Maven branch and one for each of my PRs which currently are 
merged into Joe's Maven branch, not into the main branch, because the Maven 
cutover has not been done yet. How would anyone be able to track that sort of 
thing across projects? It is not my fault that Xalan-J does not treat tests as 
first-class citizens in code land. Instead of bickering about the symptom, why 
not lend a hand and migrate the test project into this one and thus eliminate 
the root cause of the problem?
   
   One last time: Either be nice, or do not expect me to be. You want my 
respect? Treat me respectfully, or simply stop dropping your offensive comments 
into my PRs. Otherwise, Joe can thank you for me simply hopping off the project 
again. I am on the verge of doing so already, because the part of my spare time 
I dedicate to volunteer work in OSS development is too precious for having to 
spend most of it in debates with someone who obviously simply enjoys to argue.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@xalan.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@xalan.apache.org
For additional commands, e-mail: dev-h...@xalan.apache.org

Reply via email to