Syntax error in /usr/bin/chromium-browser when xdg-settings get default-web-browser is empty
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
chromium-browser (Ubuntu) |
Fix Released
|
Low
|
Olivier Tilloy | ||
Eoan |
Fix Released
|
Low
|
Olivier Tilloy |
Bug Description
[Impact]
Minor. Apparently under certain circumstances "xdg-settings get default-
This is trivial to fix by enclosing the call to "xdg-settings get default-
[Test Case]
1. Install chromium-browser
2. Patch /usr/bin/
3. From a terminal, run "chromium-browser"
Expected result: no error
Current result: /usr/bin/
[Regression Potential]
Low, enclosing a call to a command in double quotes in bash shouldn't have any undesirable side effect, and that's all that the patch does.
[Original Description]
Hi,
here is the error:
$ chromium-browser
/usr/bin/
[...]
Here is line 12 in /usr/bin/
if [ $(xdg-settings get default-
The error occurs because on my system the default-web-browser setting is unset:
$ xdg-settings get default-web-browser
[nothing]
I suggest putting double quotes around:
if [ "$(xdg-settings get default-
ProblemType: Bug
DistroRelease: Ubuntu 19.10
Package: chromium-browser 77.0.3865.
Uname: Linux 5.3.12-
ApportVersion: 2.20.11-0ubuntu8.3
Architecture: amd64
CurrentDesktop: KDE
DRM.card0-DP-1:
enabled: disabled
dpms: Off
status: disconnected
edid-base64:
modes:
DRM.card0-HDMI-A-1:
enabled: disabled
dpms: Off
status: disconnected
edid-base64:
modes:
DRM.card0-HDMI-A-2:
enabled: disabled
dpms: Off
status: disconnected
edid-base64:
modes:
DRM.card0-eDP-1:
enabled: enabled
dpms: On
status: connected
edid-base64: AP/////
modes: 1920x1080 1920x1080
Date: Fri Nov 22 10:27:14 2019
DiskUsage:
Filesystem Type Size Used Avail Use% Mounted on
/dev/mapper/
tmpfs tmpfs 7.8G 124M 7.7G 2% /dev/shm
/dev/mapper/
Lsusb:
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 003: ID 0bda:58f6 Realtek Semiconductor Corp. Integrated_
Bus 001 Device 002: ID 046d:c03e Logitech, Inc. Premium Optical Wheel Mouse (M-BT58)
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
MachineType: Dell Inc. Latitude 5590
ProcKernelCmdLine: BOOT_IMAGE=
Snap.ChromeDriv
Snap.ChromiumVe
/bin/bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
Chromium 78.0.3904.108 snap
SourcePackage: chromium-browser
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 07/19/2019
dmi.bios.vendor: Dell Inc.
dmi.bios.version: 1.10.1
dmi.board.name: 0VYDFF
dmi.board.vendor: Dell Inc.
dmi.board.version: A00
dmi.chassis.type: 10
dmi.chassis.vendor: Dell Inc.
dmi.modalias: dmi:bvnDellInc.
dmi.product.family: Latitude
dmi.product.name: Latitude 5590
dmi.product.sku: 0817
dmi.sys.vendor: Dell Inc.
Related branches
Changed in chromium-browser (Ubuntu Eoan): | |
status: | New → In Progress |
assignee: | nobody → Olivier Tilloy (osomon) |
importance: | Undecided → Low |
description: | updated |
I can reliably reproduce by modifying /usr/bin/ xdg-settings to forcefully return an empty string for default- web-browser.