elharo opened a new issue, #517:
URL: https://github.com/apache/maven-ear-plugin/issues/517

   ## Description
   
   In `EarMojo.java:881`, the return value of `File.delete()` is ignored:
   
   ```java
   resourceFile.delete();
   ```
   
   If the file cannot be deleted (e.g., locked by another process, permission 
denied), the failure goes undetected. In incremental builds, stale resources 
can remain behind.
   
   ## Expected behavior
   
   Check the return value and log a warning:
   
   ```java
   if (!resourceFile.delete()) {
       getLog().warn("Failed to delete outdated resource: " + resourceFile);
   }
   ```
   


-- 
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