Bug 1506511

Summary: virt-builder fails to parse repo file if it has blank space after the repository identifier
Product: [Community] Virtualization Tools Reporter: Christophe Fergeau <cfergeau>
Component: libguestfsAssignee: Richard W.M. Jones <rjones>
Status: CLOSED UPSTREAM QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: ptoscano, rbalakri
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-10-27 15:12:02 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Christophe Fergeau 2017-10-26 09:14:21 UTC
Edit /etc/virt-builder/repos.d/libguestfs.conf 
Add a space at the end of the "[libguestfs.org]" line
Run "virt-builder list"
Result: virt-builder: /etc/xdg/virt-builder/repos.d/libguestfs.conf: syntax error at line 1: syntax error [ignored]
Expected result: The blank space is ignored, and the repo file can be used as usual

Comment 1 Pino Toscano 2017-10-27 07:35:30 UTC
Simple patch posted yesterday:
https://www.redhat.com/archives/libguestfs/2017-October/msg00191.html

Comment 2 Pino Toscano 2017-10-27 15:12:02 UTC
Fixed with
https://github.com/libguestfs/libguestfs/commit/0d4136c69fb00289cba560f2c1e8d9ea69ad76f0
which is in libguestfs >= 1.37.32.