[jboss-jira] [JBoss JIRA] (WFCORE-3867) Space char always last char of read system property on Windows

Brian Stansberry (JIRA) issues at jboss.org
Tue May 22 12:53:00 EDT 2018


    [ https://issues.jboss.org/browse/WFCORE-3867?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13580499#comment-13580499 ] 

Brian Stansberry commented on WFCORE-3867:
------------------------------------------

OK, but we should be cautious about changing passed in values.  If our scripts are producing extra whitespace in sysprop values they should stop doing that, since it's questionably appropriate to globally trim every system property in the server code. For some cases trimming may be ok as a second line of defense (e.g. we know the property represents a path).

> Space char always last char of read system property on Windows
> --------------------------------------------------------------
>
>                 Key: WFCORE-3867
>                 URL: https://issues.jboss.org/browse/WFCORE-3867
>             Project: WildFly Core
>          Issue Type: Bug
>          Components: Server
>    Affects Versions: 5.0.0.Beta4
>            Reporter: R Searls
>            Assignee: R Searls
>            Priority: Minor
>
> On Windows each system property read has a space char as the last char of string.
> This causes failures when the property represents a directory name.  Calling 
> tmp.toPath().toRealPath() in this situation.
> ServerEnvironment line, 434  Path resolved = tmp.toPath().toRealPath();



--
This message was sent by Atlassian JIRA
(v7.5.0#75005)


More information about the jboss-jira mailing list