[
https://issues.apache.org/jira/browse/QPID-238?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Robert Greig resolved QPID-238.
-------------------------------
Resolution: Fixed
Fix Version/s: M2
Committed svn revision 493003
> Wrong call to string.Split() in AbstractQmsMessage.GetExchangeName()
> --------------------------------------------------------------------
>
> Key: QPID-238
> URL: https://issues.apache.org/jira/browse/QPID-238
> Project: Qpid
> Issue Type: Bug
> Components: Dot Net Client
> Environment: .NET 1.1 and 2.0
> Reporter: Tomas Restrepo
> Priority: Trivial
> Fix For: M2
>
> Attachments: Qpid-238.diff, Qpid-238.diff
>
>
> AbstractQmsMessage::GetExchangeName() implements a "workaround" to a supposed
> bug in string.Split(). From the comments in the file:
> Using an alternative split implementation here since it appears that
> string.Split
> is broken in .NET. It doesn't split when the first character is the delimiter.
> Here we check for the first character being the delimiter. This handles the
> case
> where ExchangeName is empty (i.e. sends will be to the default exchange).
> This is actually a non-issue; the problem is an invalid argument getting
> passed to string.Split. The current call is:
> string[] split = replyToEncoding.Split(new char[':']);
> Notice the char array argument is wrong and should've been: new char[] { ';'}.
> To avoid issues like this I propose to avoid creating explicit parameter
> arrays for string.Split() calls (which are used in several places in the code
> base) and instead let the compiler generate them instead (since it is a
> params array):
> string[] split = replyToEncoding.Split(';');
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira