|
From: Gait B. <gai...@ti...> - 2003-02-28 07:33:35
|
Hi team,
while testing in Europe, we ran into a problem with certain messages.
We tracked it down to the MessageServer.java, function =
getMessageFromFile.
It's too relaxing on the boundary strings, only checking for the =
delimiter, thus misinterpreting certain content, e.g.
<!-- my comment
-->
Basically, the boundary checks need to be changed to include comparison =
against the boundary string, see diff output below.=20
diff -r1.108 MessageServer.java
3175c3175
< !(s.startsWith(Constants.MIME_BOUNDARY_PREFIX))) {
---
> !(s.startsWith(Constants.MIME_BOUNDARY_PREFIX + boundary))) {
3211c3211
< while (!s.endsWith(Constants.MIME_BOUNDARY_PREFIX)) {
---
> while (!s.equals(Constants.MIME_BOUNDARY_PREFIX + boundary + =
Constants.MIME_BOUNDARY_PREFIX)) {
3249c3249
< !(s.startsWith(Constants.MIME_BOUNDARY_PREFIX))) {
---
> !(s.startsWith(Constants.MIME_BOUNDARY_PREFIX + boundary))) {
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Gait Boxman
Manager Advanced Technology & Standards
TIE Product Development BV
Amsterdam, The Netherlands
Tel: +31 20 658 9091 Fax: +31 20 658 9945
E-mail: gai...@ti... WWW: www.TIEglobal.com
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |