xmlstarlet crashed with SIGSEGV in xmlTextReaderGetParserLineNumber()

Bug #878246 reported by Muelli
16
This bug affects 2 people
Affects Status Importance Assigned to Milestone
xmlstarlet (Debian)
Fix Released
Unknown
xmlstarlet (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

just ran xmlstarlet on a file

ProblemType: Crash
DistroRelease: Ubuntu 11.10
Package: xmlstarlet 1.2.1-1
ProcVersionSignature: Ubuntu 3.0.0-12.20-generic 3.0.4
Uname: Linux 3.0.0-12-generic x86_64
ApportVersion: 1.23-0ubuntu3
Architecture: amd64
Date: Wed Oct 19 14:40:34 2011
ExecutablePath: /usr/bin/xmlstarlet
InstallationMedia: Ubuntu 11.04 "Natty Narwhal" - Alpha amd64 (20110201.2)
ProcCmdline: xmlstarlet sel -t --match li[@id="ca-edit"]/a/@href /tmp/wiki.html
SegvAnalysis:
 Segfault happened at: 0x7f431f2a24b0 <xmlTextReaderGetParserLineNumber+16>: mov 0x38(%rdx),%rdx
 PC (0x7f431f2a24b0) ok
 source "0x38(%rdx)" (0x007f4357) not located in a known VMA region (needed readable region)!
 destination "%rdx" ok
SegvReason: reading unknown VMA
Signal: 11
SourcePackage: xmlstarlet
StacktraceTop:
 xmlTextReaderGetParserLineNumber () from /usr/lib/libxml2.so.2
 ?? ()
 __xmlRaiseError () from /usr/lib/libxml2.so.2
 ?? () from /usr/lib/libxml2.so.2
 ?? () from /usr/lib/libxml2.so.2
Title: xmlstarlet crashed with SIGSEGV in xmlTextReaderGetParserLineNumber()
UpgradeStatus: Upgraded to oneiric on 2011-10-17 (1 days ago)
UserGroups: adm admin cdrom dialout lpadmin plugdev sambashare

Revision history for this message
Muelli (ubuntu-bugs-auftrags-killer) wrote :
visibility: private → public
Revision history for this message
Apport retracing service (apport) wrote :

StacktraceTop:
 xmlTextReaderGetParserLineNumber () from /tmp/tmpwoatLq/usr/lib/libxml2.so.2
 reportError (error=0xd17028, ptr=<optimized out>) at src/xml.c:130
 reportError (ptr=<optimized out>, error=0xd17028) at src/xml.c:115
 __xmlRaiseError () from /tmp/tmpwoatLq/usr/lib/libxml2.so.2
 ?? () from /tmp/tmpwoatLq/usr/lib/libxml2.so.2

Revision history for this message
Apport retracing service (apport) wrote : Stacktrace.txt
Revision history for this message
Apport retracing service (apport) wrote : ThreadStacktrace.txt
Changed in xmlstarlet (Ubuntu):
importance: Undecided → Medium
tags: removed: need-amd64-retrace
Revision history for this message
Tv (tv42) wrote :

I just segfaulted xmlstarlet, stack trace looks similar, easy to reproduce with this:

xmlstarlet fo </dev/null

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in xmlstarlet (Ubuntu):
status: New → Confirmed
Revision history for this message
Mathieu Trudel-Lapierre (cyphermox) wrote :

I certainly can't reproduce this crash with just calling "xmstartlet fo", so I'll assume this particular issue has been fixed already.

I also can't successfully reproduce the segfault with sel; would it be possible to please attach a sample file that fails to be parsed?

Thanks!

Changed in xmlstarlet (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Muelli (ubuntu-bugs-auftrags-killer) wrote :

Still an issue with the latest updates.

muelli@ideabox:/tmp$ xmlstarlet fo < /dev/null
-:1.1: Document is empty

^
Segmentation fault (core dumped)
muelli@ideabox:/tmp$ apt-cache policy xmlstarlet
xmlstarlet:
  Installed: 1.2.1-1
  Candidate: 1.2.1-1
  Version table:
 *** 1.2.1-1 0
        500 http://de.archive.ubuntu.com/ubuntu/ oneiric/universe amd64 Packages
        100 /var/lib/dpkg/status
muelli@ideabox:/tmp$

Changed in xmlstarlet (Ubuntu):
status: Incomplete → New
Revision history for this message
Paul Gevers (paul-climbing) wrote :

Could this be a 64 bit issue? It does NOT fail for me:

paul@stromboli ~ $ xmlstarlet fo < /dev/null
-:1.1: Document is empty

^
Start tag expected, '<' not found

^

paul@stromboli ~ $ apt-cache policy xmlstarlet
xmlstarlet:
  Installed: 1.2.1-1
  Candidate: 1.2.1-1
  Version table:
 *** 1.2.1-1 0
        500 http://nl.archive.ubuntu.com/ubuntu/ oneiric/universe i386 Packages
        100 /var/lib/dpkg/status

Revision history for this message
Tv (tv42) wrote :

Still crashes.

[0 tv@shiny ~]$ xmlstarlet fo </dev/null
-:1.1: Document is empty

^
Segmentation fault
[139 tv@shiny ~]$ dpkg -l xmlstarlet
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Description
+++-===============================-===============================-==============================================================================
ii xmlstarlet 1.2.1-1 command line XML toolkit
[0 tv@shiny ~]$ uname -a
Linux shiny 3.2.0-rc2shiny #5 SMP Sun Nov 20 11:16:47 PST 2011 x86_64 x86_64 x86_64 GNU/Linux
[0 tv@shiny ~]$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 11.10
Release: 11.10
Codename: oneiric
[0 tv@shiny ~]$

Revision history for this message
Noam Postavsky (npostavs) wrote :

Hi, upstream here, this is Bug #3362217 on the SourceForge tracker and it's been fixed since version 1.3.0.

http://sourceforge.net/tracker/?func=detail&aid=3362217&group_id=66612&atid=515106

Revision history for this message
Paul Gevers (paul-climbing) wrote :

I am closing this issue because the bug has been fixed, according to upstream in comment 11, in the latest development version of Ubuntu - Precise Pangolin.

If you need a fix for the bug in previous versions of Ubuntu, please follow the instructions for "How to request new packages" at https://help.ubuntu.com/community/UbuntuBackports#Requesting_New_Backports

@Noam Postavsky (npostavs): could you please elaborate on the bug in libxml that realy causes this issue? Is it for instance filled in Debian or Ubuntu as well?

Changed in xmlstarlet (Ubuntu):
status: New → Fix Released
Changed in xmlstarlet (Debian):
status: Unknown → Fix Released
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.