各位:我现在正在做一个彩信发送的试验,我使用NowSMS+GPRS外猫发送给我的手机,手机可以接受显示,
然后我使用mmslib中的Sender进行发送,还有mmslib中带的NokiaSender进行发送,都会发生以下错误:
//发送数据
datatosend:0000000000A004312601820687474703A2F2F6D6D|..C.`
..http://mm|
00000001073632E6D6F7465726E65742E636F6D61|sc.mo
ternet.coma|
00000002070706C69636174696F6E2F766E642E77|pplic
ation/vnd.w|
00000003061702E6D6D732D6D657373616765008C|ap.mm
s-message..|
0000000408098303030303035008D9085043C5D81|..000
005.....
>>STATE_COMPLETING
3032[CWTPSocket-10.0.0.172:9201]DEBUGwsp.CWSPMethodManager-s_methodResult_
ind
3032[CWTPSocket-10.0.0.172:9201]DEBUGwsp.CWSPMethodManager-DataLength:
292
3032[CWTPSocket-10.0.0.172:9201]DEBUGwsp.CWSPMethodManager-contentType:
text/html
3032[CWTPSocket-10.0.0.172:9201]DEBUGwsp.CWSPMethodManager-moreData:
false
3032[CWTPSocket-10.0.0.172:9201]DEBUGwsp.CWSPMethodManager-version:
1
3047[CWTPSocket-10.0.0.172:9201]DEBUGwsp.CWSPMethodManager----PAYLOAD--
-
0000000003C68746D6C3E0A093C686561643E0A09|....|
000000010093C7469746C653E6D6F7465726E6574|.moternet|
0000000202E636F6D3C2F7469746C653E0A093C2F|.com........|
0000001100A093C2F6672616D657365743E3C2F68|..|
ResponseMoreData:false
ResponseContentType:text/html
disconnectingfromWAPgateway/10.0.0.172
3047[CWTPSocket-10.0.0.172:9201]DEBUGwsp.CWSPMethodManager-STATE_COMPLETIN
G>>>STATE_NULL
3047[CWTPSocket-10.0.0.172:9201]DEBUGwtp.CWTPInitiator-67:TR_RESULT_RESi
nRESULTRESPWAIT
3047[CWTPSocket-10.0.0.172:9201]DEBUGwtp.CWTPSocket-sendingPDU_TYPE_ACK,
TID:67
3047[CWTPSocket-10.0.0.172:9201]DEBUGwtp.CWTPSocket-
datatosend:000000000180043|..C|
3047[CWTPSocket-10.0.0.172:9201]DEBUGwtp.CWTPInitiator-68:TR_INVOKE_REQi
nNULL
3047[CWTPSocket-10.0.0.172:9201]DEBUGwtp.CWTPSocket-sendingPDU_TYPE_INVOK
E,TID:68
3047[CWTPSocket-10.0.0.172:9201]DEBUGwtp.CWTPSocket-
datatosend:0000000000A00441005829368|..D..
..h|
3063[CWTPSocket-10.0.0.172:9201]DEBUGwsp.CWSPSession-s-disconnect.ind
disconnectedfromWAPgateway/10.0.0.172
3063[CWTPSocket-10.0.0.172:9201]DEBUGwtp.CWTPSocket-close():Closingsocke
t
3063[CWTPSocket-10.0.0.172:9201]DEBUGwsp.CWSPSession-STATE_CONNECTED>>>S
TATE_NULL
java.lang.ArrayIndexOutOfBoundsException:292
atnet.sourceforge.jwap.wsp.WSPDecoder.getOctet(UnknownSource)
atnet.sourceforge.jwap.wsp.WSPDecoder.getCString(UnknownSource)
atat.jku.soft.mms.lib.MMSPDU.parseSingleMmsHeader(UnknownSource)
atat.jku.soft.mms.lib.MMSPDU.parseMMSHeaders(UnknownSource)
atat.jku.soft.mms.lib.MMSPDU.setPayload(UnknownSource)
atat.jku.soft.mms.app.Sender.s_methodResult_ind(UnknownSource)
atnet.sourceforge.jwap.wsp.CWSPMethodManager.s_methodResult_ind(Unknown
Source)
atnet.sourceforge.jwap.wsp.CWSPMethodManager.tr_process(UnknownSource)
atnet.sourceforge.jwap.wtp.CWTPInitiator.process(UnknownSource)
atnet.sourceforge.jwap.wtp.CWTPSocket.run(UnknownSource)
3079[CWTPSocket-10.0.0.172:9201]ERRORlib.MMSPDU-NEEDTOSETTHEBODYTOTH
ERESTOFTHECONTENT!
即在发送给移动的网关所有数据,然后进行disconnect时发生错误,原本mmslib预期收到关于mms发送状态信息的payload,但是现在收
到的ContentType确是text/html,内容如下
moternet.com
这个payload会导致mmslib中Exception,请问各位谁做过,或者对wsp比较熟悉,帮忙解释一下,对这个信息如何进行处理,
还有我如果屏蔽掉对这个信息的处理,那么可以正常发完,但是手机收不到
我在mmslib中的配置是这样的
InetAddressgateway=InetAddress.getByName("10.0.0.172");
newSender(gateway,9201,"http://mmsc.moternet.com",b,"application/vnd.wap.mms-message");
彩信用了Nokia的测试彩信修改了里面的收发地址,还有NowSMS生成的彩信,结果都一样
分 -->
|