Age | Commit message (Collapse) | Author | |
---|---|---|---|
2022-09-05 | core: port GRegex/GMatchInfo to use autoptr() | Aleksander Morgado | |
The behavior of GRegex changed in 2.73.2 once it was ported from pcre1 to pcre2. In some cases it was made more strict, which is fine, in other cases it exposed some change in how it behaves on certain matches that is not extremely clear whether it's ok or not. See https://gitlab.gnome.org/GNOME/glib/-/issues/2729 See https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/601 See https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/621 Either way, one thing that was assumed was that initializing all GRegex/GMatchInfo variables to NULL and making sure they're NULL before they're initialized by glib (especially the GMatchInfo) was a good and safer approach. So, whenever possible, g_autoptr() is used to cleanup the allocated GMatchInfo/GRegex variables, and otherwise, g_clear_pointer() is used to ensure that no free/unref is attempted unless the given variable is not NULL, and also so that the variable is reseted to NULL after being disposed. | |||
2021-11-16 | libmm-glib: fix license in sources | Aleksander Morgado | |
The libmm-glib library is LGPLv2+, not GPLv2+. | |||
2021-08-30 | location-gps-nmea: Fix handling of multi-sentence NMEA messages | Teemu Ikonen | |
Fixes the regexp in check_append_or_replace() to accept 1. more multi-sentence NMEA messages (ALM, GSV, RTE, SFI) 2. multi-sentence NMEA messages from all talkers, not just GPS (i.e. GPGSV, GLGSV, GAGSV etc.) | |||
2021-06-25 | libmm-glib,location-gps-nmea: move deprecated methods to compat source | Aleksander Morgado | |
2021-06-25 | libmm-glib,location-gps-nmea: add missing type check in get_traces() | Aleksander Morgado | |
2020-06-29 | libmm-glib,location: avoid warnings when no traces available | Aleksander Morgado | |
ModemManager[201411]: <debug> [1593417744.011884] [modem0/ttyUSB1/gps] <-- '$GPVTG,,T,,M,,N,,K,N*2C<CR><LF>$GPGSA,A,1,,,,,,,,,,,,,,,*1E<CR><LF>$GPGGA,,,,,,0,,,,,,,,*66<CR><LF>$GPRMC,,V,,,,,,,,,,N*53<CR><LF>' (ModemManager:201411): GLib-CRITICAL **: 10:02:24.054: g_strjoinv: assertion 'str_array != NULL' failed Thread 1 "ModemManager" received signal SIGTRAP, Trace/breakpoint trap. 0x00007ffff7832473 in g_logv () from /usr/lib/libglib-2.0.so.0 (gdb) bt #0 0x00007ffff7832473 in g_logv () at /usr/lib/libglib-2.0.so.0 #1 0x00007ffff78326f0 in g_log () at /usr/lib/libglib-2.0.so.0 #2 0x00007ffff7846b5e in g_strjoinv () at /usr/lib/libglib-2.0.so.0 #3 0x00007ffff7ee9663 in mm_location_gps_nmea_get_string_variant (self=0x5555557dde50) at mm-location-gps-nmea.c:246 #4 0x00005555555e7c47 in build_location_dictionary (previous=0x0, location_3gpp=0x55555573e660, location_gps_nmea=0x5555557dde50, location_gps_raw=0x0, location_cdma_bs=0x0) at mm-iface-modem-location.c:183 ... (gdb) fr 3 #3 0x00007ffff7ee9663 in mm_location_gps_nmea_get_string_variant (self=0x5555557dde50) at mm-location-gps-nmea.c:246 246 built = g_strjoinv ("\r\n", traces); (gdb) p traces $1 = (GStrv) 0x0 | |||
2020-02-07 | iface-modem-location: plug memleaks when updating gps raw variant | Aleksander Morgado | |
The helper method returning a variant from a MMLocationGpsRaw would return already a full variant reference instead of a floating one, so we were really increasing the refcount when doing g_variant_ref_sink() in the location interface. Fix this by consolidating all helper methods in libmm-glib that return variants from the different MMLocationXX objects, so that they all return full variants instead of floating ones. | |||
2020-01-31 | libmm-glib,location-gps-nmea: avoid using deprecated build_full() method | Aleksander Morgado | |
mm-location-gps-nmea.c: In function ‘mm_location_gps_nmea_get_string_variant’: mm-location-gps-nmea.c:245:5: warning: ‘mm_location_gps_nmea_build_full’ is deprecated: Use 'mm_location_gps_nmea_get_traces' instead [-Wdeprecated-declarations] 245 | built = mm_location_gps_nmea_build_full (self); | ^~~~~ | |||
2020-01-01 | libmm-glib,nmea: deprecate mm_location_gps_nmea_build_full() | Aleksander Morgado | |
The new mm_location_gps_nmea_get_traces() is a much more generic way to retrieve the full list of traces and suits the libmm-glib API much better. | |||
2019-12-31 | libmm-glib,nmea: new method to get list of traces | Aleksander Morgado | |
Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/issues/120 | |||
2019-10-28 | libmm-glib: flag as (skip) all non-API methods | Aleksander Morgado | |
So that the GI scanner ignores them. | |||
2019-10-28 | docs,libmm-glib: provide per-version indices | Aleksander Morgado | |
2017-08-04 | location-gps-nmea: fix memory leaks | Ben Chan | |
There are potential memory leaks in MMLocationGpsNmea: - When the `trace' string provided to location_gps_nmea_take_trace() isn't added to the hash table, its ownership is still considered transferred. It should thus be freed. Similarly, the `trace_type' string isn't added the hash table and should thus be freed. - mm_location_gps_nmea_add_trace() duplicates a given trace string and then passes the trace copy to location_gps_nmea_take_trace(). When location_gps_nmea_take_trace() returns FALSE, the ownership of the copy isn't transferred. mm_location_gps_nmea_add_trace() should thus free the copy. This patch fixes the above memory leaks by having location_gps_nmea_take_trace() always take the ownership of the `trace' string and internally free `trace' and `trace_type' when necessary. | |||
2013-10-24 | libmm-glib: fix several introspection annotations | Aleksander Morgado | |
2012-10-04 | libmm-glib,location-gps-nmea: improve documentation | Aleksander Morgado | |
2012-10-04 | build: merge libmm-common into libmm-glib | Aleksander Morgado | |
It's pointless to have libmm-common around, just merge it into libmm-glib and make ModemManager depend on libmm-glib directly. At the end, the non-common stuff in libmm-glib is really minimal. |