icewm icon indicating copy to clipboard operation
icewm copied to clipboard

Crash at start when offline / Mailbox-Check

Open einmueller opened this issue 5 years ago • 7 comments

Hi!

At first: Thank you very much for fork the code and carry on! I use IceWm for about 25 years now on different platforms from sparc/solaris, over OpenPandora to intel/linux and BSD. When it was kind of dead, I tried different WM and DEs but nothing compares to IceWm as my daily driver.

But I have a (very small) problem with icewm, that exists for some versions now.

I have configured an pop3s-Server to check for new Mails. The Server uses starttls (centos with dovecot at the other side). When I start IceWm and the Servername could not be resolved (Network-Manager needs its time), icewm crashes. Not every time, but very often. As a workaround, I resolved my Mailserver in /etc/hosts and IceWm is as stable as in the last 25 years. There are no issues, when I cut the Network after starting IceWm. Then, I got the red mailbox-icon, as normal.

TaskBarShowMailboxStatus=1 # 0/1 MailBoxPath="pop3s://:@*****:110/"

I use IceWm 1.8.2 with Manjaro, but the problem also exists with prior versions, but (afaik) not with the last releases before the fork.

Perhaps it is a fast patch for who knows the actual code (at least I hope so). I have maintained IceWm for OpenPandora and patched some issues with APM Battery Status a long time ago, but for now the real life takes to much time to dive into the code again for myself...

Greetings and carry on,

Tobias

einmueller avatar Sep 19 '20 11:09 einmueller

Hi! Thanks for your kind words. I'm amazed you waited so long. You need to bring a backtrace. Choose from valgrind, catchsegv or use LD_PRELOAD=/lib/libSegFault.so.

gijsbers avatar Sep 19 '20 12:09 gijsbers

Hi!

No problem. I have attached the backtrace and the corefile.

To reproduce I have change my normal credentials to test-credentials and an unknown server: MailBoxPath="pop3s://USER:[email protected]:110/"

I have to say, that Manjaro is at version 1.8.2. If needed, I could compile the latest version from source.

icewm.segfault.txt icewm.core.gz

Thank you very much!

greetings,

Tobias

einmueller avatar Sep 19 '20 20:09 einmueller

Sorry, this isn't really helpful unless you point to a download location to an unstripped version of your icewm binary (with debug symbols).

I suggest you install Xephyr and get the latest version 1.8.3 from www.ice-wm.org or git. There, a) configure the environment with "CXXFLAGS=-g -O0" (before configuring, -DCMAKE_BUILD_TYPE=Debug as cmake option in case you prefer cmake variant) and build.

To simplify testing, I suggest to install Xephyr, start Xephyr like "Xephyr :1" and run "./icewm --display=:1".

A good smoke test is also running this within valgrind .

Code7R avatar Sep 19 '20 21:09 Code7R

Hi!

Ok, no problem, here it is (at least, i hope). Thank you for your patience.

I have compiled icewm 1.8.3 from ice-wm.org with "CXXFLAGS=-g -O0" as suggested. I used another config directory with only the attached preferences-file and called icewm with ICEWM_PRIVCFG pointing to my configs. Thank you for pointing to Xephyr for debugging, should have had the idea myself. I'm a little bit rusty ;-)

Attached are the core-file, my preferences, the backtrace and the output of valgrind. The icewm-binary is also there. Because of the file size limit i could not attach the vgcore-file, but you can get it and also the whole binary-testing-tree at my private seafile-server: https://daus.sirtobi.com/d/d7b7b212cebe4c23b425/

Please let me know if I should shoot up some more commands for further testing,

thank you very much,

Tobias

icewm.gz icewm.core.gz icewm.segfault.txt icewm.valgrind.txt

einmueller avatar Sep 20 '20 06:09 einmueller

I have seen the attached fix from gijsbers a little to late.

It seems to work for me. So the ticket could be closed, if there are not other issues I didn't see and I could help to solve.

einmueller avatar Sep 20 '20 06:09 einmueller

Question: you specify pop3s with port 110, but icewm only uses encryption for ports 993 and 995. Is that what you hoped for? Why not just say pop3?

gijsbers avatar Sep 20 '20 07:09 gijsbers

Hi!

Good question, I thought it did StartTLS on 110, but never checked if it really does. I should reactivate port 995 on my server then... ;-)

Thank you very much and have a nice Sunday!

greetings,

Tobias

einmueller avatar Sep 20 '20 08:09 einmueller