To make things neater, sort the files listed in instrospection's Makefile
alphabetically, and sort the files listed in all.xml alphabetically within
logical groups.
Signed-off-by: Thomas Tuttle <ttuttle@chromium.org>
Comparing dumps from UML190 in different modes, UML290, and PC5740
revealed what the 'service' bit was, which matches up nicely with
the SERVICE_* strings in the Windows connection manager DLLs if
you interpret them in reverse numerical order.
For the global mode stuff, looking at USB wire captures shows that
C8 03 and C8 04 get used right before the NETWORK_INFO (C8 0B)
shows access technology changes, which means they are probably the
commands that switch global mode around.
The introspection data specified the Send() method to return
an array of unsigned integers, presumably the indexes of the
messages just sent. But the code wasn't doing that, leading
to a crash when dbus-glib tried to interpret garbage on the
return.
The problem is that sms_send_auth_cb() gave async_call_done()
as the callback for sending the SMS, but that method just calls
dbus_g_method_return() with no return arguments. dbus-glib
interprets the arguments of dbus_g_method_return() according
to the XML introspection data, and thus it was attempting to
read the non-existent argument as an 'au' and getting garbage.
Fix that by actually returning an array of message indexes from
the SMS send code, and propagate that back to the SMS dbus
code so it can return something sensible.
Like the MF627 for some reason. Also, the format appears to be
more like the DM_CMD_VERSION_INFO response where at least the
comp_date and comp_time fields are the same size as
VERSION_INFO, just with some padding between.
The first byte of the PDU is the SMSC length, but it's not
the padded SMSC length. So we need to subtract the actual
byte index of the start of the message from length of the
PDU, and since the PDU creation function knows all about
where the SMSC address stops and the message begins, just
have it return that length instead of making the callers
calculate it.