Unknown LC_CTYPE causes crash

Bug #1378406 reported by Dan Watkins
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
command-not-found
Confirmed
Undecided
Unassigned

Bug Description

command-not-found crashes when the LC_CTYPE is defined in the environment but is not installed. This can be seen via SSH which sets the LC_CTYPE.

$ env
TERM=xterm
SHELL=/bin/bash
<snip>
LANG=en_US.UTF-8
<snip>
LC_CTYPE=en_GB.UTF-8

$ foo
Sorry, command-not-found has crashed! Please file a bug report at:
https://bugs.launchpad.net/command-not-found/+filebug
Please include the following information with the report:

command-not-found version: 0.2.44

$ unset LC_CTYPE

$ foo
No command 'foo' found, did you mean:
 Command 'fio' from package 'fio' (universe)
 Command 'goo' from package 'goo' (universe)
 Command 'fop' from package 'fop' (main)
 Command 'fox' from package 'objcryst-fox' (universe)
 Command 'xoo' from package 'xoo' (universe)
 Command 'fgo' from package 'fgo' (universe)
 Command 'zoo' from package 'zoo' (universe)
foo: command not found

Steps to reproduce:

Run "LC_CTYPE=foo f"
---
ApportVersion: 2.14.1-0ubuntu3.4
Architecture: amd64
DistroRelease: Ubuntu 14.04
Package: command-not-found 0.3ubuntu12
PackageArchitecture: all
ProcVersionSignature: Ubuntu 3.13.0-36.63-generic 3.13.11.6
Tags: trusty uec-images
Uname: Linux 3.13.0-36-generic x86_64
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: adm dip plugdev sudo video
_MarkForUpload: True

Revision history for this message
Ben Howard (darkmuggle-deactivatedaccount) wrote :

Marking as confirmed, I can see this happen as well.

Changed in command-not-found:
status: New → Confirmed
description: updated
description: updated
Revision history for this message
Dan Watkins (oddbloke) wrote : Dependencies.txt

apport information

tags: added: apport-collected trusty uec-images
description: updated
Revision history for this message
Dan Watkins (oddbloke) wrote : ProcEnviron.txt

apport information

Revision history for this message
Zygmunt Krynicki (zyga) wrote : Re: [Bug 1378406] Re: Unknown LC_CTYPE causes crash
Download full text (3.2 KiB)

http://www.zygoon.pl/2013/04/why-is-command-not-found-crashing.html

On Tue, Oct 7, 2014 at 5:20 PM, Ben Howard <email address hidden> wrote:
> Marking as confirmed, I can see this happen as well.
>
> ** Changed in: command-not-found
> Status: New => Confirmed
>
> ** Description changed:
>
> - When I SSH on to a pristine cloud instance, I see a crash:
> + command-not-found crashes when the LC_TYPE is defined in the environment
> + but is not installed. This can be seen via SSH which sets the LC_TYPE.
>
> $ env
> TERM=xterm
> SHELL=/bin/bash
> <snip>
> LANG=en_US.UTF-8
> <snip>
> LC_CTYPE=en_GB.UTF-8
>
> $ foo
> Sorry, command-not-found has crashed! Please file a bug report at:
> https://bugs.launchpad.net/command-not-found/+filebug
> Please include the following information with the report:
>
> command-not-found version: 0.2.44
>
> $ unset LC_CTYPE
>
> $ foo
> No command 'foo' found, did you mean:
> - Command 'fio' from package 'fio' (universe)
> - Command 'goo' from package 'goo' (universe)
> - Command 'fop' from package 'fop' (main)
> - Command 'fox' from package 'objcryst-fox' (universe)
> - Command 'xoo' from package 'xoo' (universe)
> - Command 'fgo' from package 'fgo' (universe)
> - Command 'zoo' from package 'zoo' (universe)
> + Command 'fio' from package 'fio' (universe)
> + Command 'goo' from package 'goo' (universe)
> + Command 'fop' from package 'fop' (main)
> + Command 'fox' from package 'objcryst-fox' (universe)
> + Command 'xoo' from package 'xoo' (universe)
> + Command 'fgo' from package 'fgo' (universe)
> + Command 'zoo' from package 'zoo' (universe)
> foo: command not found
>
> Steps to reproduce:
>
> Run "LC_CTYPE=foo f"
>
> ** Description changed:
>
> - command-not-found crashes when the LC_TYPE is defined in the environment
> - but is not installed. This can be seen via SSH which sets the LC_TYPE.
> + command-not-found crashes when the LC_CTYPE is defined in the
> + environment but is not installed. This can be seen via SSH which sets
> + the LC_CTYPE.
>
> $ env
> TERM=xterm
> SHELL=/bin/bash
> <snip>
> LANG=en_US.UTF-8
> <snip>
> LC_CTYPE=en_GB.UTF-8
>
> $ foo
> Sorry, command-not-found has crashed! Please file a bug report at:
> https://bugs.launchpad.net/command-not-found/+filebug
> Please include the following information with the report:
>
> command-not-found version: 0.2.44
>
> $ unset LC_CTYPE
>
> $ foo
> No command 'foo' found, did you mean:
> Command 'fio' from package 'fio' (universe)
> Command 'goo' from package 'goo' (universe)
> Command 'fop' from package 'fop' (main)
> Command 'fox' from package 'objcryst-fox' (universe)
> Command 'xoo' from package 'xoo' (universe)
> Command 'fgo' from package 'fgo' (universe)
> Command 'zoo' from package 'zoo' (universe)
> foo: command not found
>
> Steps to reproduce:
>
> Run "LC_CTYPE=foo f"
>
> --
> You received this bug notification because you are subscribed to
> command-not-found.
> https://bugs.launchpad.net/bugs/1378406
>
> Title:
> Unknown LC_CTYPE causes crash
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/command-...

Read more...

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.