-
jjj333_p (any pronouns)
> var attrlen = StropheStanza.get_attribute_count(el); > var attrsraw: RawPointer<cpp.Void> = NativeGc.allocGcBytesRaw(attrlen * 2 * untyped __cpp__("sizeof(char*)"), false); > var attrsarray: RawPointer<RawConstPointer<Char>> = untyped __cpp__("static_cast<const char**>(attrsraw)"); > var attrsptr = cpp.Pointer.fromRaw(attrsarray); > StropheStanza.get_attributes(el, attrsarray, attrlen * 2); > singpolyma, perhaps i dont understand but this looks like what im doing now ↺
-
jjj333_p (any pronouns)
but i checked and it legitimately seems to just be returning a single element which then my code is mishandling
-
jjj333_p (any pronouns)
https://downloadable.pain.agency/file_share/068ed83f-28c4-7b60-b060-9d35e03469c1/7577a769-3926-4da4-8bf4-bf3e4b70af24.png
-
jjj333_p (any pronouns)
my understanding was that it was gonna fill in every atribute key with a value right after, i dont think i was expecting it to be a single item
-
jjj333_p (any pronouns)
im also confused why my null checks arent working
-
jjj333_p (any pronouns)
https://downloadable.pain.agency/file_share/068ed853-fa2e-7e68-8b1f-d29966e3bc72/a1e3e36d-adb6-4973-8d56-393c3078d7fe.png
-
jjj333_p (any pronouns)
well its not null is it
-
jjj333_p (any pronouns)
okay turns out i think the error is elsewhere in my code, however why is the namespace on <body> a jabber:client
-
jjj333_p (any pronouns)
i thought there was no explicit namespace
-
jjj333_p (any pronouns)
im so fucking confused. it gets to the end of the constructor fine, (verified with a print) but it doesnt return back
-
jjj333_p (any pronouns)
i wonder if i got too clever with unique pointers
-
singpolyma
> okay turns out i think the error is elsewhere in my code, however why is the namespace on <body> a jabber:client is that is the right namespace on body for c2s ↺
-
singpolyma
No element can ever have "no namespace" in xmpp
-
moparisthebest
π΅πΆ undefined behavior πΆπ΅
-
Goot the ticklegoblin!
Technically, if you use a prefix for both the stream namespace and the jabber:client namespace, and just don't use either for an element...
-
singpolyma
lol maybe if you're very careful you could. No XML doc ought to have elements with no namespace though, especially in xmpp where we make it hard on purpose