http://nagoya.apache.org/bugzilla/show_bug.cgi?id=975
*** shadow/975 Sun Mar 25 11:15:05 2001
--- shadow/975.tmp.9953 Wed Apr 25 22:33:06 2001
***************
*** 2,10 ****
| Problem of loading environment variables |
+----------------------------------------------------------------------------+
| Bug #: 975 Product: Ant |
! | Status: RESOLVED Version: 1.3 |
! | Resolution: FIXED Platform: PC |
! | Severity: Normal OS/Version: All |
| Priority: Medium Component: Core tasks |
+----------------------------------------------------------------------------+
| Assigned To: [EMAIL PROTECTED] |
--- 2,10 ----
| Problem of loading environment variables |
+----------------------------------------------------------------------------+
| Bug #: 975 Product: Ant |
! | Status: REOPENED Version: 1.3 |
! | Resolution: Platform: PC |
! | Severity: Normal OS/Version: Linux |
| Priority: Medium Component: Core tasks |
+----------------------------------------------------------------------------+
| Assigned To: [EMAIL PROTECTED] |
***************
*** 68,71 ****
------- Additional Comments From [EMAIL PROTECTED] 2001-03-25 11:15 -------
Sometimes (for example with a default installation of cygwin) there are
environment-variables containing a new-line. We now ignore anything after the
! first line and log the ignored lines with warning-level.
--- 68,107 ----
------- Additional Comments From [EMAIL PROTECTED] 2001-03-25 11:15 -------
Sometimes (for example with a default installation of cygwin) there are
environment-variables containing a new-line. We now ignore anything after the
! first line and log the ignored lines with warning-level.
!
! ------- Additional Comments From [EMAIL PROTECTED] 2001-04-25 22:33 -------
! Might I offer the following modification as opposed to the currently
! implemented fix? It handles the issue a little more directly.
! I have used it successfully to handle multi-line ENV values "correctly".
!
! Thanks for your attention to this,
! greg.fenton
!
!
! 242a243,246
! >
! > String key = null;
! > StringBuffer value;
! >
! 248,253c252,264
! < if (pos == -1) {
! < log("Ignoring: " + entry, Project.MSG_WARN);
! < } else {
! < props.put(prefix + entry.substring(0, pos),
! < entry.substring(pos + 1));
! < }
! ---
! >
! > if ( pos > 0 ) { // found a new envvar
! > key = prefix + entry.substring(0, pos);
! > props.put(key,
! > entry.substring(pos + 1));
! > } else if ( null != key ) {
! > // the previous envvar value contains this line too...
! > value = new StringBuffer( (String)props.get( key ) );
! > value.append( System.getProperty("line.separator") );
! > value.append( entry );
! > props.put( key, value.toString() );
! > }
! >