| 166 y = xmlnode_new_child(iq->node, "error"); |
166 y = xmlnode_new_child(iq->node, "error"); |
| 167 xmlnode_set_attrib(y, "code", code); |
167 xmlnode_set_attrib(y, "code", code); |
| 168 if(!strcmp(code, "406")) { |
168 if(!strcmp(code, "406")) { |
| 169 z = xmlnode_new_child(y, "not-acceptable"); |
169 z = xmlnode_new_child(y, "not-acceptable"); |
| 170 xmlnode_set_attrib(y, "type", "modify"); |
170 xmlnode_set_attrib(y, "type", "modify"); |
| 171 xmlnode_set_attrib(z, "xmlns", "urn:ietf:params:xml:ns:xmpp-stanzas"); |
171 xmlnode_set_namespace(z, "urn:ietf:params:xml:ns:xmpp-stanzas"); |
| 172 } else if(!strcmp(code, "404")) { |
172 } else if(!strcmp(code, "404")) { |
| 173 z = xmlnode_new_child(y, "not-found"); |
173 z = xmlnode_new_child(y, "not-found"); |
| 174 xmlnode_set_attrib(y, "type", "cancel"); |
174 xmlnode_set_attrib(y, "type", "cancel"); |
| 175 xmlnode_set_attrib(z, "xmlns", "urn:ietf:params:xml:ns:xmpp-stanzas"); |
175 xmlnode_set_namespace(z, "urn:ietf:params:xml:ns:xmpp-stanzas"); |
| 176 } |
176 } |
| 177 jabber_iq_send(iq); |
177 jabber_iq_send(iq); |
| 178 |
178 |
| 179 jabber_oob_xfer_free(xfer); |
179 jabber_oob_xfer_free(xfer); |
| 180 } |
180 } |