Skip to content
Snippets Groups Projects
Commit 48d2fa39 authored by Aleksander Morgado's avatar Aleksander Morgado Committed by Dan Williams
Browse files

port-serial: Flow Control property is flags, not enum

MMFlowControl is a flags enumeration, so change the property type to
match that, or we'll end up with nasty criticals during runtime.

    (ModemManager:30758): GLib-GObject-CRITICAL **: 10:54:26.435: g_param_spec_enum: assertion 'G_TYPE_IS_ENUM (enum_type)' failed

    Thread 1 "ModemManager" received signal SIGTRAP, Trace/breakpoint trap.
    0x00007ffff71f2a96 in ?? () from /usr/lib/libglib-2.0.so.0
    (gdb) bt
    #0  0x00007ffff71f2a96 in  () at /usr/lib/libglib-2.0.so.0
    #1  0x00007ffff71f3def in g_logv () at /usr/lib/libglib-2.0.so.0
    #2  0x00007ffff71f3fe0 in g_log () at /usr/lib/libglib-2.0.so.0
    #3  0x00007ffff72d90ac in g_param_spec_enum () at /usr/lib/libgobject-2.0.so.0
    #4  0x000055555564caf2 in mm_port_serial_class_init (klass=0x5555557607c0) at mm-port-serial.c:2101
    #5  0x000055555564759a in mm_port_serial_class_intern_init (klass=0x5555557607c0) at mm-port-serial.c:49
    #6  0x00007ffff72ea9b4 in g_type_class_ref () at /usr/lib/libgobject-2.0.so.0
    #7  0x00007ffff72eab5a in g_type_class_ref () at /usr/lib/libgobject-2.0.so.0
    #8  0x00007ffff72d0f53 in g_object_new_valist () at /usr/lib/libgobject-2.0.so.0
    #9  0x00007ffff72d103a in g_object_new () at /usr/lib/libgobject-2.0.so.0
    #10 0x000055555564e187 in mm_port_serial_at_new (name=0x55555576e280 "ttyUSB4", subsys=MM_PORT_SUBSYS_TTY) at mm-port-serial-at.c:533
    #11 0x0000555555602512 in serial_open_at (self=0x555555715390) at mm-port-probe.c:1285
    #12 0x00007ffff71ecb49 in g_main_context_dispatch () at /usr/lib/libglib-2.0.so.0
    #13 0x00007ffff71ecf59 in  () at /usr/lib/libglib-2.0.so.0
    #14 0x00007ffff71ed272 in g_main_loop_run () at /usr/lib/libglib-2.0.so.0
    #15 0x00005555555957e0 in main (argc=3, argv=0x7fffffffe458) at
    main.c:181

Also, rename the property to match the naming convention of other
properties in the same object.
parent e3c2f0e9
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment