lsb

lsb_release incorrectly parses quoted strings

Bug #1558744 reported by Erwin Schrodinger
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
lsb
New
Undecided
Unassigned

Bug Description

If the contents of /etc/redhat-release are enclosed in quotes, lsb_release incorrectly parses the contents:

# cat /etc/*-release
"Red Hat Enterprise Linux Client release 7.0 (Maipo)"

# lsb_release -a
LSB Version: :core-4.1-amd64:core-4.1-noarch:cxx-4.1-amd64:cxx-4.1-noarch:desktop-4.1-amd64:desktop-4.1-noarch:languages-4.1-amd64:languages-4.1-noarch:printing-4.1-amd64:printing-4.1-noarch
Distributor ID: "RedHatEnterpriseClient
Description: "Red Hat Enterprise Linux Client release 7.0 (Maipo)"
Release: 7.0
Codename: Maipo

(Note that the value returned for Distributor ID is missing the closing quotation mark.)

Removing the quotes yields correct output:

# cat /etc/redhat-release
Red Hat Enterprise Linux Client release 7.0 (Maipo)

# lsb_release -a
LSB Version: :core-4.1-amd64:core-4.1-noarch:cxx-4.1-amd64:cxx-4.1-noarch:desktop-4.1-amd64:desktop-4.1-noarch:languages-4.1-amd64:languages-4.1-noarch:printing-4.1-amd64:printing-4.1-noarch
Distributor ID: RedHatEnterpriseClient
Description: Red Hat Enterprise Linux Client release 7.0 (Maipo)
Release: 7.0
Codename: Maipo

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.