elharo commented on code in PR #177:
URL: https://github.com/apache/maven-shared-jar/pull/177#discussion_r4155007748


##########
src/main/java/org/apache/maven/shared/jar/identification/exposers/RepositorySearchExposer.java:
##########
@@ -77,9 +83,11 @@ public void expose(JarIdentification identification, 
JarAnalyzer jarAnalyzer) {
             repohits.addAll(repositoryHashSearch.searchFileHash(hash));
         }
 
-        String bytecodehash = bytecodeHashAnalyzer.computeHash(jarAnalyzer);
-        if (bytecodehash != null) {
-            
repohits.addAll(repositoryHashSearch.searchBytecodeHash(bytecodehash));
+        try {
+            String bytecodeHash = 
bytecodeHashAnalyzer.computeHashCode(jarAnalyzer);
+            
repohits.addAll(repositoryHashSearch.searchBytecodeHash(bytecodeHash));
+        } catch (IOException e) {
+            logger.warn("Unable to calculate the bytecode hash.", e);

Review Comment:
   I'm not sure this is working. all this does is move one ignored exception 
into a different method. It doesn't deal with or really report the I/O error.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to