[
http://jira.codehaus.org/browse/MJAVACC-35?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_112855
]
Benjamin Bentmann commented on MJAVACC-35:
------------------------------------------
{code:java}
File f1 = new File("pom.xml");
File f2 = new File("./pom.xml");
if ( !f1.getAbsolutePath().equals( f2.getAbsolutePath() ) )
; // different?
{code}
{code:java}
File f1 = new File("pom.xml");
File f2 = new File("POM.xml");
if ( !f1.getAbsolutePath().equals( f2.getAbsolutePath() ) )
; // different? some file systems are case-insensitve...
{code}
Fortunately, we are all using canonicalized paths to configure plugins ;-)
Anyway, the usage of getAbsolutePath() seems kind of really dangerous in the
patch: java.io.File resolves relative paths against the "current" directory but
I guess most users would expect the path to be relative to the base directory
of the current project (which might be different, e.g. during reactor builds).
> If input and output directory are equal then input files are emptied
> --------------------------------------------------------------------
>
> Key: MJAVACC-35
> URL: http://jira.codehaus.org/browse/MJAVACC-35
> Project: Maven 2.x JavaCC Plugin
> Issue Type: Bug
> Affects Versions: 2.3
> Environment: WinXP
> Reporter: Tim Pizey
> Attachments: JavaCCMojo.patch
>
>
> If the inputDirectory is the same as the outputDirectory, a situation which
> no doubt should not happen, but has to in javacc itself,
> then the input files are replaced with zero byte size files.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email