Release Telegram


So I decided to work again on that right-click crash bug this Weekend. I started a gdb session with current build this saturday and find out that I had to rebuilt Qt (a special static lib build) with debug info to be ebble to go further in the debug
Here is the (short) gdb sesion
Code:
The program 'Telegram' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadValue (integer parameter out of range for operation)'.
  (Details: serial 1438 error_code 2 request_code 139 minor_code 51)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the --sync command line
   option to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)
[Thread 0x46588430 (LWP 29758) exited]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x45d88430 (LWP 29757)]
0x01291e6c in QAbstractEventDispatcher::registerTimer(int, Qt::TimerType, QObject*) ()
(gdb) bt
#0  0x01291e6c in QAbstractEventDispatcher::registerTimer(int, Qt::TimerType, QObject*) ()
#1  0x012c9994 in QObject::startTimer(int, Qt::TimerType) ()
#2  0x012d23f0 in QTimer::start() ()
#3  0x00fcf7c4 in QNetworkConfigurationManagerPrivate::startPolling() ()
#4  0x00fcfcd4 in QNetworkConfigurationManagerPrivate::updateConfigurations() ()
#5  0x0000000c in ?? ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
(gdb) info thread
  Id   Target Id         Frame
  17   Thread 0x4c2db430 (LWP 29782) "Qt HTTP thread" 0x43816620 in poll () from /lib/libc.so.6
  15   Thread 0x49af1430 (LWP 29780) "MTP::internal::" 0x43816620 in poll () from /lib/libc.so.6
  14   Thread 0x4a2f1430 (LWP 29770) "Qt HTTP thread" 0x43816620 in poll () from /lib/libc.so.6
  12   Thread 0x4aaf1430 (LWP 29768) "MTP::internal::" 0x43816620 in poll () from /lib/libc.so.6
  8    Thread 0x48783430 (LWP 29763) "QThread" 0xffff0520 in ?? ()
  7    Thread 0x47f83430 (LWP 29762) "QThread" 0xffff0520 in ?? ()
  5    Thread 0x46d88430 (LWP 29759) "QThread" 0xffff0520 in ?? ()
* 3    Thread 0x45d88430 (LWP 29757) "Qt bearer threa" 0x01291e6c in QAbstractEventDispatcher::registerTimer(int, Qt::TimerType, QObject*) ()
  2    Thread 0x4497d430 (LWP 29756) "QXcbEventReader" 0x43816620 in poll () from /lib/libc.so.6
  1    Thread 0x43e920a0 (LWP 29750) "Telegram" QMap<QString, WebImage*>::~QMap (this=0x20ef00c <(anonymous namespace)::webImages>, __in_chrg=<optimized out>) at ../../qt/include/QtCore/qmap.h:335
(gdb) q
So I started rebuilding Qt.... It finished sunday afternoon... Than I had to cleanily recompile Telegram itself (because of changed PCH files)... It ended this monday morning.
So I quickly started a new debug session before going to work... to find out it doesn't crash anymore!

So I just took that binary, stripped it and create a new PND... Qt is a debug build, not a release build, but I don't think the missing optimisation is really important for that type of software.

Build 09
-----------

  • Fixed right-click crash
 
Last edited:
I realy appreciate your Patience and Work with it.
Thank you @ptitSeb
and i tried it and i do not like it to bring you bad News.
Now it crash on animated Gifs.

"WSEGL_InitialiseDisplay: DRI2OpenConnection failed Qt: Session management error: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed [swscaler @ 0x2d94ab0] No accelerated colorspace conversion found from yuv420p to bgra. ./runscript.sh: line 82: 6007 Bus error ./Telegram "$*"

and the right Click Error is still here:

Qt: Session management error: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed The program 'Telegram' received an X Window System error. This probably reflects a bug in the program. The error was 'BadValue'. (Details: serial 3181 error_code 2 request_code 139 minor_code 51) (Note to programmers: normally, X errors are reported asynchronously; that is, you will receive the error a while after causing it. To debug your program, run it with the --sync command line option to change this behavior. You can then get a meaningful backtrace from your debugger if you break on the gdk_x_error() function.) AL lib: (EE) alc_cleanup: 1 device not closed"

I will try to reflash my Pandora and test it again,
Maybe there are some encounters with my other Tests and i try a "clean" Test
 
Really? Strange, it did work for my (before packaging), I got the local menu comming... .Bbut no idea about animated gif, unless I forgot to add gif in my rebuild of Qt :( . Now that I think of it, yes, that's probably... I need to compile Qt and everything again :'(

I'll do more tests tonight about the right click.
 
Sorry for the News.
I will try a clean install first and will report here. :$
Edit:
After reflash,reupdate the same ..sorry :(
 
Last edited:
New build on the repo. I have fixed the right-click crash for good this time.

After a lot of debugging and recompiling, it turns out the issue was in the mouse handling using Xinput2.
So, export this QT_XCB_NO_XI2_MOUSE=1 in the runscript fixed the issue.

I don't know if animated gif is still broken (as this is a fresh build). If it's still broken, I'll fallback to build 08 binary..


Build 10
-----------

  • Really fixed right-click crash
 
Last edited:
Thx i will test it this Evening..now i must cooking first here.
We make a big Pot Soup for a few Days and Spinach with Potatoes and grilled Sausage.
I will be busy for near 2 Hours ;)
 
I'll test it in a few minutes.
[doublepost=1472909535,1472908768][/doublepost]I'm not sure if it was a gif that did it as it crashes before I can see what tried to load, but it was some type of image.

Code:
WSEGL_InitialiseDisplay: DRI2OpenConnection failed
Qt: Session management error: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed
[swscaler @ 0x4ea35c20] No accelerated colorspace conversion found from yuv420p to bgra.
[swscaler @ 0x2402810] No accelerated colorspace conversion found from yuv420p to bgra.
./runscript.sh: line 83:  3146 Bus error               ./Telegram "$*"
 
I'll test it in a few minutes.
[doublepost=1472909535,1472908768][/doublepost]I'm not sure if it was a gif that did it as it crashes before I can see what tried to load, but it was some type of image.

Code:
WSEGL_InitialiseDisplay: DRI2OpenConnection failed
Qt: Session management error: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed
[swscaler @ 0x4ea35c20] No accelerated colorspace conversion found from yuv420p to bgra.
[swscaler @ 0x2402810] No accelerated colorspace conversion found from yuv420p to bgra.
./runscript.sh: line 83:  3146 Bus error               ./Telegram "$*"
I must confirm this.
Tried the same with Build8 and same Error there because the animated Gifs.

The right Mouse Click Problem is realy good solved now ;)

Edit:
Google said its an FFMPEG Problem with this Lib inside FFMpeg:
https://www.ffmpeg.org/libswscale.html

@ptitSeb
I found here a Howto solve that:
http://alexsleat.co.uk/2011/01/09/h...m-yuv420p-to-bgr24-opencv-2-2-0-ubuntu-10-10/

Edit Edit:
I checked that Link and it seem to simply need a new giflib and FFmpeg Version
 
Last edited:
Ok, it's not super clear now.

About the crash: does it crash also with Build 08?

About the No accelerared color space: this is a not the issue, just a warning that the conversion between the 2 colorspace will be done by software (and that's fine for the Pandora). The real issue is the "Bus error", but I need a full backtrace to be able to debug. But for that, I need to make a "debug" pnd (non-stripped).

But first, I need an awnser, does it crash with build 08, because I had to impression that this one was not crashing.
 
I had a Segmention Fault starting it with GDB :(
photo_2016-08-31_15-22-30.jpg


Edit:
i give it a second Try
 
Last edited:
Maybe you need a swapfile, it's huge with the debug infos.

Also, don't right click or it will crash (or add QT_XCB_NO_XI2_MOUSE=1 to the already long command line).
 
I got it with Swap..good Hint:
Here is the Whole GDB Output:
Code:
(gdb) r
Starting program: /mnt/utmp/telegram/Telegram
warning: File "/lib/libthread_db-1.0.so" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load".
To enable execution of this file add
    add-auto-load-safe-path /lib/libthread_db-1.0.so
line to your configuration file "/mnt/utmp/telegram/home/.gdbinit".
To completely disable this security protection add
    set auto-load safe-path /
line to your configuration file "/mnt/utmp/telegram/home/.gdbinit".
For more information about this security protection see the
"Auto-loading safe path" section in the GDB manual.  E.g., run from the shell:
    info "(gdb)Auto-loading safe path"
warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available.
warning: File "/lib/libthread_db-1.0.so" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load".
warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available.
Qt: gdb: -nograb added to command-line options.
     Use the -dograb option to enforce grabbing.
[New LWP 3137]
Qt: Session management error: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed
[New LWP 3138]
[New LWP 3139]
[New LWP 3140]
[New LWP 3143]
[New LWP 3144]
[New LWP 3145]
[LWP 3143 exited]
[New LWP 3146]
[New LWP 3147]
[New LWP 3148]
[LWP 3147 exited]
[New LWP 3149]
[New LWP 3150]
[New LWP 3151]
[New LWP 3152]
[New LWP 3153]
[New LWP 3154]
[New LWP 3155]
[New LWP 3156]
[New LWP 3157]
[New LWP 3158]
[New LWP 3159]
[New LWP 3160]
[New LWP 3161]
[LWP 3157 exited]
[LWP 3153 exited]
[LWP 3156 exited]
[LWP 3152 exited]
[New LWP 3162]
[swscaler @ 0x25d31a0] No accelerated colorspace conversion found from yuv420p to bgra.

Program received signal SIGBUS, Bus error.
[Switching to LWP 3162]
0x411bfa58 in ?? () from /mnt/utmp/telegram//lib/libswscale.so.4
(gdb) bt
#0  0x411bfa58 in ?? () from /mnt/utmp/telegram//lib/libswscale.so.4
#1  0x4119be30 in ?? () from /mnt/utmp/telegram//lib/libswscale.so.4
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
 
Ok, I have uploaded a new version of the Telegram pnd. Still the same link. This one should have debug info on the FFmpeg libs, so the gdb BackTrace should give more details this time, hopefully enough so I can fix it.
 
Good Morning,,here ist the Output ;)
Starting program: /mnt/utmp/telegram/Telegram
warning: File "/lib/libthread_db-1.0.so" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load".
To enable execution of this file add
add-auto-load-safe-path /lib/libthread_db-1.0.so
line to your configuration file "/mnt/utmp/telegram/home/.gdbinit".
To completely disable this security protection add
set auto-load safe-path /
line to your configuration file "/mnt/utmp/telegram/home/.gdbinit".
For more information about this security protection see the
"Auto-loading safe path" section in the GDB manual. E.g., run from the shell:
info "(gdb)Auto-loading safe path"
warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available.
warning: File "/lib/libthread_db-1.0.so" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load".
warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available.
Qt: gdb: -nograb added to command-line options.
Use the -dograb option to enforce grabbing.
[New LWP 2974]
Qt: Session management error: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed
[New LWP 2975]
[New LWP 2976]
[New LWP 2977]
[New LWP 2980]
[New LWP 2981]
[New LWP 2982]
[LWP 2980 exited]
[New LWP 2983]
[New LWP 2984]
[New LWP 2985]
[LWP 2984 exited]
[New LWP 2986]
[New LWP 2987]
[New LWP 2988]
[New LWP 2989]
[New LWP 2990]
[New LWP 2991]
[New LWP 2992]
[LWP 2990 exited]
[LWP 2989 exited]
[LWP 2986 exited]
[New LWP 2993]
[New LWP 2994]
[New LWP 2995]
[New LWP 2996]
[New LWP 2997]
[LWP 2996 exited]
[swscaler @ 0x2484b00] No accelerated colorspace conversion found from yuv420p to bgra.

Program received signal SIGBUS, Bus error.
[Switching to LWP 2994]
0x411bfaf0 in ff_yuv420p_to_bgra_neon () at libswscale/arm/yuv2rgb_neon.S:279
279 libswscale/arm/yuv2rgb_neon.S: No such file or directory.
(gdb) bt
#0 0x411bfaf0 in ff_yuv420p_to_bgra_neon ()
at libswscale/arm/yuv2rgb_neon.S:279
#1 0x00000000 in ?? ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
 
Back
Top