1. 13 Sep, 2017 1 commit
  2. 08 Aug, 2017 1 commit
  3. 04 Aug, 2017 2 commits
    • Ben Chan's avatar
      location-gps-nmea: fix memory leaks · 29cbac4a
      Ben Chan authored and Aleksander Morgado's avatar Aleksander Morgado committed
      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.
      
      (cherry picked from commit e33aa019)
      29cbac4a
    • Ben Chan's avatar
      broadband-modem-qmi: fix potential use-after-freed issues · 30fe8f4f
      Ben Chan authored and Aleksander Morgado's avatar Aleksander Morgado committed
      This patch fixes some potential use-after-freed issues in
      dms_get_ids_ready(). When an invalid ESN / MEID is retrieved,
      `ctx->self->priv->esn' / `ctx->self->priv->meid' is freed but not reset
      to NULL. If no IMEI is retrieved, `str' can be set to the already freed
      `ctx->self->priv->esn' / `ctx->self->priv->meid' and then propagated to
      a GSimpleAsyncResult object.
      
      (cherry picked from commit 0d3cca2c)
      30fe8f4f
  4. 03 Aug, 2017 2 commits
    • Ben Chan's avatar
      sms-part-cdma: add missing break statements in cause_code_to_delivery_state · 33047539
      Ben Chan authored and Aleksander Morgado's avatar Aleksander Morgado committed
      This patch fixes cause_code_to_delivery_state() by adding two missing
      break statements for the case ERROR_CLASS_TEMPORARY and
      ERROR_CLASS_PERMANENT in the `switch (error_class)` statement. Without
      the break statements, the switch always falls through to the default and
      returns MM_SMS_DELIVERY_STATE_UNKNOWN for an `error_class' of value
      ERROR_CLASS_TEMPORARY or ERROR_CLASS_PERMANENT.
      
      (cherry picked from commit 0bb01ab6)
      33047539
    • Ben Chan's avatar
      libmm-glib,firmware: fix unique_id checks · ddafb5ae
      Ben Chan authored and Aleksander Morgado's avatar Aleksander Morgado committed
      The following checks in mm_modem_firmware_select() and
      mm_modem_firmware_select_sync() could result in a NULL pointer
      dereference if `unique_id' is NULL:
      
        g_return_if_fail (unique_id != NULL || unique_id[0] == '\0')
        g_return_val_if_fail (unique_id != NULL || unique_id[0] == '\0', FALSE)
      
      This patch fixes the checks to properly verify that `unique_id' is
      neither NULL nor an empty string.
      
      (cherry picked from commit bae45907)
      ddafb5ae
  5. 19 Jul, 2017 1 commit
  6. 23 Jun, 2017 2 commits
  7. 03 Mar, 2017 1 commit
  8. 13 Feb, 2017 5 commits
  9. 10 Feb, 2017 1 commit
    • Aleksander Morgado's avatar
      libmm-glib: set clear func by default in the MMModemPortInfo array · ea33672c
      Aleksander Morgado authored
      
      
      So that we don't leak the port names allocated within each
      MMModemPortInfo.
      
          ==261== 672 bytes in 84 blocks are definitely lost in loss record 7,314 of 7,383
          ==261== at 0x402C51E: malloc (vg_replace_malloc.c:299)
          ==261== by 0x4484878: g_malloc (gmem.c:94)
          ==261== by 0x449D51D: g_strdup (gstrfuncs.c:363)
          ==261== by 0x44B5B73: g_variant_dup_string (gvariant.c:1529)
          ==261== by 0x44B945E: g_variant_valist_get_nnp (gvariant.c:4775)
          ==261== by 0x44B945E: g_variant_valist_get_leaf (gvariant.c:4945)
          ==261== by 0x44B945E: g_variant_valist_get (gvariant.c:5126)
          ==261== by 0x44B922C: g_variant_valist_get (gvariant.c:5161)
          ==261== by 0x44B9FC9: g_variant_get_va (gvariant.c:5388)
          ==261== by 0x44BA3C5: g_variant_get_child (gvariant.c:5486)
          ==261== by 0x6613FA8: mm_common_ports_variant_to_garray (mm-common-helpers.c:238)
          ==261== by 0x6601AB9: ensure_internal_ports (mm-modem.c:766)
          ==261== by 0x6603E42: mm_modem_peek_ports (mm-modem.c:825)
          ==261== by 0x65CD94D: owns_port (nm-modem-broadband.c:196)
      Reported-by: default avatarPiotr Figiel <p.figiel@camlintechnologies.com>
      (cherry picked from commit 91613543)
      ea33672c
  10. 08 Feb, 2017 1 commit
    • Piotr Figiel's avatar
      libmm-glib: fix leaking bearer_path string · 9f779e2f
      Piotr Figiel authored and Aleksander Morgado's avatar Aleksander Morgado committed
          ==261== 482 bytes in 12 blocks are definitely lost in loss record 7,290 of 7,383
          ==261== at 0x402C51E: malloc (vg_replace_malloc.c:299)
          ==261== by 0x4484878: g_malloc (gmem.c:94)
          ==261== by 0x449D51D: g_strdup (gstrfuncs.c:363)
          ==261== by 0x44B5B73: g_variant_dup_string (gvariant.c:1529)
          ==261== by 0x44B945E: g_variant_valist_get_nnp (gvariant.c:4775)
          ==261== by 0x44B945E: g_variant_valist_get_leaf (gvariant.c:4945)
          ==261== by 0x44B945E: g_variant_valist_get (gvariant.c:5126)
          ==261== by 0x44B922C: g_variant_valist_get (gvariant.c:5161)
          ==261== by 0x44B9FC9: g_variant_get_va (gvariant.c:5388)
          ==261== by 0x44BA1DB: g_variant_get (gvariant.c:5335)
          ==261== by 0x664E2EF: mm_gdbus_modem_simple_call_connect_finish (mm-gdbus-modem.c:22451)
          ==261== by 0x6608A08: simple_connect_ready (mm-modem-simple.c:154)
          ==261== by 0x429136F: g_task_return_now (gtask.c:1107)
          ==261== by 0x4291A69: g_task_return (gtask.c:1165)
      
      (cherry picked from commit 255e4c76)
      9f779e2f
  11. 04 Jan, 2017 3 commits
  12. 28 Sep, 2016 1 commit
  13. 01 Sep, 2015 1 commit
  14. 31 Aug, 2015 1 commit
    • Dan Williams's avatar
      broadband-modem-mbim: disable CDMA capabilities until we actually support MBIM+CDMA · c1d80032
      Dan Williams authored
      CDMA-capable modems (like a Sierra EM7355) will fail to even enable,
      because the internal CDMA code tries to initialize using AT commands and
      that fails because many MBIM modems don't have an AT port.  We should
      figure out how to support minimal MBIM + CDMA using MBIM instead of
      AT-anything.
      
      [mm-broadband-modem.c:9000] enabling_step(): Modem has CDMA capabilities, enabling the Modem CDMA interface...
      [mm-iface-modem-cdma.c:946] mm_iface_modem_cdma_run_registration_checks(): Running registration checks (CDMA1x: 'yes', EV-DO: 'yes')
      [mm-broadband-modem.c:7397] setup_registration_checks_context_complete_and_free(): Will skip all QCDM-based registration checks
      [mm-broadband-modem.c:7418] setup_registration_checks_context_complete_and_free(): Will skip generic detailed registration check, we don't have Sprint commands
      [mm-iface-modem-cdma.c:768] registration_check_step(): Starting QCDM-based registration checks
      [mm-iface-modem-cdma.c:780] registration_check_step():   Skipping all QCDM-based checks and falling back to AT-based checks
      [mm-iface-modem-cdma.c:823] registration_check_step(): Starting AT-based registration checks
      [mm-iface-modem-cdma.c:641] get_service_status_ready(): Could not get service status: No AT port available to run command
      [mm-iface-modem.c:1392] __iface_modem_update_state_internal(): Modem /org/freedesktop/ModemManager1/Modem/0: state changed (enabling -> disabled)
      
      (cherry picked from commit 2034918d)
      c1d80032
  15. 20 Jul, 2015 1 commit
    • Dan Williams's avatar
      iface-modem: don't check the cache when asking for required unlocks · ad207bbf
      Dan Williams authored
      When passing known_lock=UNKNOWN to mm_iface_modem_update_lock_info()
      we actually do want to ask the modem itself for locks instead of
      checking the cache.  For example, when an unknown error is returned
      after performing PIN/PUK operations, the cache value may well be
      NONE if that was the prior lock state, and that bypasses the modem
      which might now be locked.  Thus the state gets messed up.
      
      Reproducer is to send 'ChangePin' with the wrong "old" PIN 3 times,
      then send a wrong PUK.  No error was returned from mmcli and
      the modem's lock state was shown as 'none'.
      
      (cherry picked from commit 9b051b14)
      ad207bbf
  16. 02 Jul, 2015 4 commits
  17. 31 Mar, 2015 1 commit
    • Dan Williams's avatar
      base-manager: quiet message about unsupported ports · 0ad842b6
      Dan Williams authored
      This message gets printed for all netdevs and ttys, including most
      machines normal ethernet/Wi-Fi interfaces.  It seems a bit less critical
      than 'warning' level would indicate.
      
      ModemManager[32097]: <warn>  Couldn't find support for device at '/sys/devices/pci0000:00/0000:00:19.0': not supported by any plugin
      ModemManager[32097]: <warn>  Couldn't find support for device at '/sys/devices/pci0000:00/0000:00:1c.1/0000:02:00.0': not supported by any plugin
      
      (cherry picked from commit 9293fd2b)
      0ad842b6
  18. 02 Mar, 2015 1 commit
  19. 26 Jan, 2015 1 commit
  20. 28 Oct, 2014 1 commit
  21. 11 Feb, 2014 1 commit
  22. 04 Feb, 2014 1 commit
  23. 30 Jan, 2014 4 commits
  24. 29 Jan, 2014 1 commit
  25. 26 Jan, 2014 1 commit
    • Guido Günther's avatar
      broadband-modem-qmi: Fix compilation error due to removed variable · c5cfa2ca
      Guido Günther authored and Aleksander Morgado's avatar Aleksander Morgado committed
      otherwise we fail with:
      
      CC       ModemManager-mm-broadband-modem-qmi.o
      mm-broadband-modem-qmi.c: In function ‘process_gsm_info’:
      mm-broadband-modem-qmi.c:4182:18: error: ‘egprs_support_valid’ undeclared (first use in this function)
                       &egprs_support_valid,  &egprs_support,
                        ^
      mm-broadband-modem-qmi.c:4182:18: note: each undeclared identifier is reported only once for each function it appears in
      mm-broadband-modem-qmi.c:4182:40: error: ‘egprs_support’ undeclared (first use in this function)
                       &egprs_support_valid,  &egprs_support,
      c5cfa2ca