You are not logged in.

#1 2012-09-18 15:35:33

Jinmenju
Member
Registered: 2012-09-17
Posts: 9

[SOLVED] dmenu segfaults

I recently tried installing dmenu from the repositories, however whenever I run dmenu_run, I get the following error:

/usr/bin/dmenu_run: lin 15: 1879 Segmentation fault           dmenu "$@" < "$cache"

I'm running it on a 64-bit system with kernel version 3.5.3-1.

I have not been able to find any information regarding the problem, nor have I been able to solve it myself.

Would anybody else here happen to know what causes this segfault and possibly how to fix it?

Last edited by Jinmenju (2012-09-18 18:27:48)

Offline

#2 2012-09-18 16:12:30

bohoomil
Member
Registered: 2010-09-04
Posts: 2,376
Website

Re: [SOLVED] dmenu segfaults

Assuming that dmenu has created a cache file which should be located either in '~/.cache/dmenu_run' or '~/.dmenu_cache', please check what happens if you run

dmenu < ~/.cache/dmenu_run

:: Registered Linux User No. 223384

:: github
:: infinality-bundle+fonts: good looking fonts made easy

Offline

#3 2012-09-18 17:28:24

Jinmenju
Member
Registered: 2012-09-17
Posts: 9

Re: [SOLVED] dmenu segfaults

a '~/.cache/dmenu_run' exists. When running the command it gives the following:

no locale support
Segmentation fault

and then exits.

Offline

#4 2012-09-18 17:35:00

bohoomil
Member
Registered: 2010-09-04
Posts: 2,376
Website

Re: [SOLVED] dmenu segfaults

I believe you've got an answer:

no locale support

What is the output of 'locale -a' and 'locale' respectively?

Last edited by bohoomil (2012-09-18 17:35:23)


:: Registered Linux User No. 223384

:: github
:: infinality-bundle+fonts: good looking fonts made easy

Offline

#5 2012-09-18 18:00:32

Jinmenju
Member
Registered: 2012-09-17
Posts: 9

Re: [SOLVED] dmenu segfaults

'locale -a' gives:

C
en_DK
en_DK.iso88591
en_DK.utf8
en_GB
en_GB.iso88591
en_GB.utf8
POSIX

While 'locale' gives:

LANG=en_DK.utf8
LC_CTYPE="en_DK.utf8"
LC_NUMERIC="en_DK.utf8"
LC_TIME="en_DK.utf8"
LC_COLLATE="en_DK.utf8"
LC_MONETARY="en_DK.utf8"
LC_MESSAGES="en_DK.utf8"
LC_PAPER="en_DK.utf8"
LC_NAME="en_DK.utf8"
LC_ADDRESS="en_DK.utf8"
LC_TELEPHONE="en_DK.utf8"
LC_MEASUREMENT="en_DK.utf8"
LC_IDENTIFICATION="en_DK.utf8"
LC_ALL=

Offline

#6 2012-09-18 18:09:42

bohoomil
Member
Registered: 2010-09-04
Posts: 2,376
Website

Re: [SOLVED] dmenu segfaults

I'm not sure if this is going to have any effect at all, but try adding

en_US.UTF-8 UTF-8
en_US ISO-8859-1

to your /etc/locale.gen, regenerate locale and check dmenu again.


:: Registered Linux User No. 223384

:: github
:: infinality-bundle+fonts: good looking fonts made easy

Offline

#7 2012-09-18 18:27:17

Jinmenju
Member
Registered: 2012-09-17
Posts: 9

Re: [SOLVED] dmenu segfaults

Well adding them did nothing in itself... but I tried doing a:

 export LANG="en_GB.utf8" 

and apparently that fixed it :}... I find it very strange for the program to segfault because of the locale.

However since a solution has been found I'm marking this as solved. Thank you very much for your assistance smile

Offline

#8 2012-09-19 13:06:08

UncleNinja
Member
From: Georgia, USA
Registered: 2011-07-09
Posts: 10
Website

Re: [SOLVED] dmenu segfaults

This happened to me because I had a bogus $LANG in /etc/locale.conf.

Instead of

LANG="en_US.UTF-8"

I had

LANG="en_US.UTF_8"

Evidently dmenu assumes you have a valid locale.

(apologies for the one day bump, I just wanted to say what the problem was for the sake of google searchers)

Last edited by UncleNinja (2012-09-19 13:06:39)

Offline

#9 2012-10-08 21:09:20

Biowaste
Member
From: Denmark
Registered: 2010-06-22
Posts: 12
Website

Re: [SOLVED] dmenu segfaults

I had the same error, and It appears that dmenu dislikes my locale:

LANG="en_DK.UTF-8"

...while

LANG="da_DK.UTF-8"

works perfectly.

Even though locale -a knows about en_DK:

C
da_DK.utf8
en_DK.utf8
en_US.utf8
POSIX

And locale says this:

LANG=en_DK.UTF-8
LC_CTYPE="en_DK.UTF-8"
LC_NUMERIC="en_DK.UTF-8"
LC_TIME="en_DK.UTF-8"
LC_COLLATE="en_DK.UTF-8"
LC_MONETARY="en_DK.UTF-8"
LC_MESSAGES="en_DK.UTF-8"
LC_PAPER="en_DK.UTF-8"
LC_NAME="en_DK.UTF-8"
LC_ADDRESS="en_DK.UTF-8"
LC_TELEPHONE="en_DK.UTF-8"
LC_MEASUREMENT="en_DK.UTF-8"
LC_IDENTIFICATION="en_DK.UTF-8"
LC_ALL=

Any clues how to fix that? I greatly prefer en_DK, because of what's lost in translation, and to keep danish date/time formats.

Last edited by Biowaste (2012-10-08 21:16:51)

Offline

Board footer

Powered by FluxBB