Bug 884322 - crash due to unexpected exception on connection loss in libpqxx
Summary: crash due to unexpected exception on connection loss in libpqxx
Keywords:
Status: CLOSED DUPLICATE of bug 884323
Alias: None
Product: Fedora
Classification: Fedora
Component: libpqxx
Version: 17
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Andreas Bierfert
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-12-05 22:28 UTC by Serge Pavlovsky
Modified: 2012-12-05 22:40 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-12-05 22:40:58 UTC
Type: Bug


Attachments (Terms of Use)
tested patch (373 bytes, patch)
2012-12-05 22:28 UTC, Serge Pavlovsky
no flags Details | Diff

Description Serge Pavlovsky 2012-12-05 22:28:45 UTC
Created attachment 658426 [details]
tested patch

Description of problem:

pqxx::connection_base::encoding_code() is marked as non-throwing, but it calls activate(), which throws on connection loss, causing call of std::unexcpected() and subsequent crash
other similar functions, for example pqxx::connection_base::protocol_version(), just return 0 when not connected

please apply attached patch

Version-Release number of selected component (if applicable):
3.2-0.2

Comment 1 Serge Pavlovsky 2012-12-05 22:40:58 UTC
i got an error from cgi during posting, but turns out it was posted successfully

*** This bug has been marked as a duplicate of bug 884323 ***


Note You need to log in before you can comment on or make changes to this bug.