RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1895002 - GLib-CRITICAL **: 15:27:38.047: g_utf8_strlen: assertion 'p != NULL || max == 0' failed
Summary: GLib-CRITICAL **: 15:27:38.047: g_utf8_strlen: assertion 'p != NULL || max ==...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: flatpak
Version: 8.4
Hardware: x86_64
OS: Unspecified
unspecified
medium
Target Milestone: rc
: 8.0
Assignee: David King
QA Contact: Martin Krajnak
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-11-05 14:39 UTC by Martin Krajnak
Modified: 2021-05-18 15:26 UTC (History)
1 user (show)

Fixed In Version: flatpak-1.8.3-1.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-05-18 15:26:23 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github flatpak flatpak pull 3854 0 None closed Avoid critical error in remote-info command 2020-12-18 10:11:11 UTC

Description Martin Krajnak 2020-11-05 14:39:34 UTC
Description of problem:
The issue claims to be fixes in 1.8.2 in upstream but I can reproduce this in both Fedora and rhel:
https://github.com/flatpak/flatpak/pull/3854

Version-Release number of selected component (if applicable):
flatpak-1.8.2-1.el8.x86_64

How reproducible:
always

Steps to Reproduce:
1.flatpak remote-add --user --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
2.flatpak -y install flathub org.gnome.Eolie
3.$ flatpak remote-info --log flathub org.gnome.Eolie
      

Actual results:
  ID: org.gnome.Eolie
       Ref: app/org.gnome.Eolie/x86_64/stable
      Arch: x86_64
    Branch: stable
Collection: org.flathub.Stable
  Download: 12.9 MB
 Installed: 37.9 MB
   Runtime: org.gnome.Platform/x86_64/3.34
       Sdk: org.gnome.Sdk/x86_64/3.34


(flatpak remote-info:71966): GLib-CRITICAL **: 15:38:06.886: g_utf8_strlen: assertion 'p != NULL || max == 0' failed
    Commit: (null)
    Parent: a459779fdde9defdf18be8e9277a1d3f5ba13bbfc190f86a930fe4ad578b2d89
   Subject: Appdata: add a patch to fix it (974981c3)
      Date: 2019-09-13 15:18:14 +0000
   History: 

Expected results:
No critical message and the Commit is not (null)

Additional info:
G_DEBUG=fatal-criticals gdb flatpak                                             
GNU gdb (GDB) Fedora 9.2-7.fc33
Copyright (C) 2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from flatpak...
Reading symbols from /usr/lib/debug/usr/bin/flatpak-1.8.2-2.fc33.x86_64.debug...
(gdb) r remote-info --log flathub org.gnome.Eolie
Starting program: /usr/bin/flatpak remote-info --log flathub org.gnome.Eolie
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
[New Thread 0x7fffe8dac640 (LWP 22974)]
[New Thread 0x7fffe3fff640 (LWP 22975)]
[New Thread 0x7fffe37fe640 (LWP 22976)]
[New Thread 0x7fffe2ffd640 (LWP 22980)]
[Thread 0x7fffe2ffd640 (LWP 22980) exited]
[Detaching after fork from child process 22989]
[Detaching after fork from child process 22991]
[Detaching after fork from child process 22993]
[Detaching after fork from child process 22995]
[Detaching after fork from child process 22997]
[Detaching after fork from child process 22999]
[Detaching after fork from child process 23001]

Eolie - Web browser

        ID: org.gnome.Eolie
       Ref: app/org.gnome.Eolie/x86_64/stable
      Arch: x86_64
    Branch: stable
   Version: 0.9.63
   License: GPL-3.0+
Collection: org.flathub.Stable
  Download: 12.9 MB
 Installed: 37.9 MB
   Runtime: org.gnome.Platform/x86_64/3.34
       Sdk: org.gnome.Sdk/x86_64/3.34


(/usr/bin/flatpak remote-info:22970): GLib-CRITICAL **: 12:25:31.376: g_utf8_strlen: assertion 'p != NULL || max == 0' failed

Thread 1 "flatpak" received signal SIGTRAP, Trace/breakpoint trap.
0x00007ffff7610d23 in g_logv () from /lib64/libglib-2.0.so.0
(gdb) thread apply all bt full

Thread 4 (Thread 0x7fffe37fe640 (LWP 22976)):
#0  0x00007ffff74a2a0f in poll () at /lib64/libc.so.6
#1  0x00007ffff7659d1e in g_main_context_iterate.constprop () at /lib64/libglib-2.0.so.0
#2  0x00007ffff76086ab in g_main_loop_run () at /lib64/libglib-2.0.so.0
#3  0x00007ffff7c172c3 in server_thread_func () at /lib64/libpolkit-agent-1.so.0
#4  0x00007ffff7635ede in g_thread_proxy () at /lib64/libglib-2.0.so.0
#5  0x00007ffff75813f9 in start_thread () at /lib64/libpthread.so.0
#6  0x00007ffff74adb03 in clone () at /lib64/libc.so.6

Thread 3 (Thread 0x7fffe3fff640 (LWP 22975)):
#0  0x00007ffff74a2a0f in poll () at /lib64/libc.so.6
#1  0x00007ffff7659d1e in g_main_context_iterate.constprop () at /lib64/libglib-2.0.so.0
#2  0x00007ffff76086ab in g_main_loop_run () at /lib64/libglib-2.0.so.0
#3  0x00007ffff78476b6 in gdbus_shared_thread_func.lto_priv () at /lib64/libgio-2.0.so.0
#4  0x00007ffff7635ede in g_thread_proxy () at /lib64/libglib-2.0.so.0
#5  0x00007ffff75813f9 in start_thread () at /lib64/libpthread.so.0
#6  0x00007ffff74adb03 in clone () at /lib64/libc.so.6

Thread 2 (Thread 0x7fffe8dac640 (LWP 22974)):
#0  0x00007ffff74a2a0f in poll () at /lib64/libc.so.6
#1  0x00007ffff7659d1e in g_main_context_iterate.constprop () at /lib64/libglib-2.0.so.0
#2  0x00007ffff760641f in g_main_context_iteration () at /lib64/libglib-2.0.so.0
#3  0x00007ffff7608031 in glib_worker_main () at /lib64/libglib-2.0.so.0
#4  0x00007ffff7635ede in g_thread_proxy () at /lib64/libglib-2.0.so.0
#5  0x00007ffff75813f9 in start_thread () at /lib64/libpthread.so.0
#6  0x00007ffff74adb03 in clone () at /lib64/libc.so.6

Thread 1 (Thread 0x7ffff62dd940 (LWP 22970)):
#0  0x00007ffff7610d23 in g_logv () at /lib64/libglib-2.0.so.0
#1  0x00007ffff7610f8f in g_log () at /lib64/libglib-2.0.so.0
#2  0x00007ffff7635508 in g_utf8_strlen () at /lib64/libglib-2.0.so.0
#3  0x00005555555e03ce in ellipsize_string_full (text=<optimized out>, len=108, mode=FLATPAK_ELLIPSIZE_MODE_END) at app/flatpak-builtins-utils.c:1006
--Type <RET> for more, q to quit, c to continue without paging--c
        ret = 0x0
#4  0x00005555555a51ee in flatpak_builtin_remote_info (argc=<optimized out>, argv=<optimized out>, cancellable=0x0, error=<optimized out>) at app/flatpak-builtins-remote-info.c:309
        formatted_commit = <optimized out>
        len = <optimized out>
        store = 0x5555556f80d0
        app = <optimized out>
        license = <optimized out>
        rows = 35
        cols = 120
        width = 108
        version = 0x55555819ca44 "0.9.63"
        context = 0x555555709400
        dirs = 0x5555556ffc40
        preferred_dir = 0x5555556fb020
        commit_v = 0x7fffdc009660
        remote = <optimized out>
        pref = <optimized out>
        default_branch = 0x0
        kinds = <optimized out>
        matched_kinds = (FLATPAK_KINDS_APP | FLATPAK_KINDS_RUNTIME)
        id = 0x555555718940 "org.gnome.Eolie"
        arch = 0x0
        branch = 0x0
        parts = 0x555555703430
        kind = FLATPAK_KINDS_APP
        ref = 0x555555906fa0 "app/org.gnome.Eolie/x86_64/stable"
        commit = 0x0
        parent = 0x5555571f8540 "a459779fdde9defdf18be8e9277a1d3f5ba13bbfc190f86a930fe4ad578b2d89"
        state = 0x555555739b40
        friendly = 1
        xa_metadata = 0x55555581d0a0 "[Application]\nname=org.gnome.Eolie\nruntime=org.gnome.Platform/x86_64/3.34\nsdk=org.gnome.Sdk/x86_64/3.34\ncommand=eolie\n\n[Context]\nshared=network;ipc;\nsockets=x11;wayland;pulseaudio;\ndevices=dri;\nfilesy"...
        collection_id = 0x55555581cf00 "org.flathub.Stable"
        eol = 0x0
        eol_rebase = 0x0
        metakey = 0x555558bcc4c0
        installed_size = <optimized out>
        download_size = <optimized out>
        formatted_installed_size = 0x555557661940 "37.9 MB"
        formatted_download_size = 0x555557661960 "12.9 MB"
        subject = 0x55555581d3e6 "Appdata: add a patch to fix it (974981c3)"
        timestamp = <optimized out>
        formatted_timestamp = 0x5555576ac390 "2019-09-13 15:18:14 +0000"
        sparse_cache = {base = 0x7ffff7886b44, size = 140737345459717}
#5  0x000055555559d52d in flatpak_run (res_error=0x7fffffffdb18, argv=<optimized out>, argc=<optimized out>) at app/flatpak-main.c:783
        command = 0x5555556c4950 <commands+1680>
        success = 0
        error = 0x0
        cancellable = 0x0
        prgname = 0x5555556dcfb0 "/usr/bin/flatpak remote-info"
        command_name = 0x7fffffffe140 "remote-info"
        polkit_agent = 0x5555556fae50
        __func__ = "flatpak_run"
        error = 0x0
        ret = <optimized out>
        action = {__sigaction_handler = {sa_handler = 0x55555559e540 <handle_sigterm>, sa_sigaction = 0x55555559e540 <handle_sigterm>}, sa_mask = {__val = {0 <repeats 16 times>}}, sa_flags = 0, sa_restorer = 0x0}
#6  main (argc=<optimized out>, argv=<optimized out>) at app/flatpak-main.c:888
        error = 0x0
        ret = <optimized out>
        action = {__sigaction_handler = {sa_handler = 0x55555559e540 <handle_sigterm>, sa_sigaction = 0x55555559e540 <handle_sigterm>}, sa_mask = {__val = {0 <repeats 16 times>}}, sa_flags = 0, sa_restorer = 0x0}

Comment 2 David King 2020-12-08 15:29:49 UTC
The fix is included upstream in 1.8.3, so the most recent flatpak build fixes this.

Comment 5 Martin Krajnak 2020-12-09 14:42:59 UTC
I can't reproduced with flatpak-1.8.3-1.el8.x86_64

Comment 7 errata-xmlrpc 2021-05-18 15:26:23 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (flatpak bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2021:1781


Note You need to log in before you can comment on or make changes to this bug.