Asmack file transfer progress always at 0.0

前端 未结 2 1038
梦谈多话
梦谈多话 2021-01-17 05:46

Hi there i am using asmack-android-19-0.8.10.jar and openfire to develop file transfer. i refered to harryjoy.me but i have problems when sending the file where transfer.get

相关标签:
2条回答
  • 2021-01-17 06:00

    Implementation looks buggy, e.g.

    <feature xmlns="http://jabber.org/protocol/feature-neg">
            <x xmlns="jabber:x:data" type="submit">
                <field var="stream-method">
                    <value>http://jabber.org/protocol/bytestreams</value>
                    <value>http://jabber.org/protocol/ibb</value>
                </field>
            </x>
        </feature>
    

    is wrong reply, because XEP-0095 say:

    If acceptable the Receiver MUST select one of the presented stream types to use.

    Try to use only one stream method and/or submit bugreport to Smack.

    0 讨论(0)
  • 2021-01-17 06:05

    First, thanks for the detailed question. That makes it easy to get an idea what could be wrong. While vitalyster is right, the stanza is a violation of the spec, I don't think this is the cause for the problem.

    What looks wrong is that we don't see any result IQs for the set IQs that carry a data element, ie the stanza of Example 7 in XEP-47 is missing. That's all I can say with the provided information. I suggest you grab a debugger to find the root cause. Good that (a)Smack is open source

    Edit: You call SmackAndroid.init(Context) as aSmacks README tells you to do, or not?

    0 讨论(0)
提交回复
热议问题