| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
|
|
|
|
| |
We want to mark some TLV fields as reserved and not exposed through the
public API due to alignment or other issues.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change triggers an API break.
When building structs to be included in the public header, we were just relying
on using the 'public_format' of each variable. This is an error, as the variable
may be more complex than just public/private. E.g. could be another struct, or
an array, or a fixed sized string, as in the example.
In particular, this bug currently affects one public type, where one of its
elements changes from being just a pointer to a string to a fixed sized array of
4 bytes.
The following type is changed from:
typedef struct _QmiMessageNasGetCellLocationInfoOutputGeranInfoCellElement {
guint32 cell_id;
gchar * plmn;
guint16 lac;
guint16 geran_absolute_rf_channel_number;
guint8 base_station_identity_code;
guint16 rx_level;
} QmiMessageNasGetCellLocationInfoOutputGeranInfoCellElement;
To:
typedef struct _QmiMessageNasGetCellLocationInfoOutputGeranInfoCellElement {
guint32 cell_id;
gchar plmn[4];
guint16 lac;
guint16 geran_absolute_rf_channel_number;
guint8 base_station_identity_code;
guint16 rx_level;
} QmiMessageNasGetCellLocationInfoOutputGeranInfoCellElement;
Thanks to Joseba Sanjuan <joseba.sanjuan@gmail.com> for finding the bug.
|
| |
|
| |
|
|
|
|
|
|
|
| |
https://bugzilla.redhat.com/show_bug.cgi?id=1031738
Reported-by: Florian Weimer <fweimer@redhat.com>
Signed-off-by: Thomas Haller <thaller@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Try to handle buggy firmware, or just make the library more robust, by
validating the read TLV before really reading it. If a TLV is not considered
valid, we just skip it for now.
E.g.: the "Detailed Service Status" TLV (0x21) in the "NAS Get Serving System"
message is supposed to be a sequence of 5 bytes, but some models (e.g. ZTE MF683)
end up sending only the first 4 bytes.
|
|
|
|
|
| |
Among the tons of fixes done here, we now generate some per-service .sections
file which we then concatenate to build the final libqmi-glib-sections.txt file.
|
|
|
|
|
|
|
| |
When an array is required to be passed in an input TLV, the user who created it
is responsible for freeing it. Therefore, we should not dump the static array
element clear function in these cases, or these unused methods will end up
breaking the compilation.
|
|
|
|
|
|
|
|
|
| |
For those variables which are containers of other variables (struct, sequence
and array), ensure we call `emit_helper_methods()' in order to generate variable
specific dispose() helpers and such.
This fixes the case of nested arrays of structs (arrays of structs with arrays of
structs whithin).
|
|
The `sequence' variable types are defined in the same way as `struct' types, but
the generated implementation is completely different:
* Struct TLVs will generate public struct types, and the getter/setter methods
will pass a single variable of that new struct type.
* Sequence TLVs will not generate any new public nor private type. The getter
and setter methods will pass N items, one for each member of the sequence.
It should be safe to do so and maintain API/ABI compatibility afterwards, as
existing TLVs are not expected to change.
|