[ZBX-5981] Zabbix Segfaults on invalid assert()s Created: 2012 Dec 12 Updated: 2017 May 30 Resolved: 2012 Dec 23 |
|
Status: | Closed |
Project: | ZABBIX BUGS AND ISSUES |
Component/s: | Proxy (P), Server (S) |
Affects Version/s: | 2.0.3 |
Fix Version/s: | 2.0.5rc1, 2.1.0 |
Type: | Incident report | Priority: | Critical |
Reporter: | Heiko Wundram | Assignee: | Unassigned |
Resolution: | Fixed | Votes: | 0 |
Labels: | crash, segfault, trivial | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified | ||
Environment: |
Gentoo with standard ebuild 2.0.3 (contains no patches against the official source). |
Attachments: | zbx-2.0.3-assert.patch |
Description |
The DB-API high-level abstractions for Zabbix and the Zabbix server contain some invalid asserts, which contain code with side-affects and which isn't executed on a -DNDEBUG build (which is the default build argument on Gentoo). This leads to random segfaults due to the use of unitialized values. The attached patch file fixes the corresponding assert()s to have the actual code outside of the assert, and leaves only the test in the assert. I haven't checked whether this is already fixed in 2.0.4, but couldn't find any other mention on the JIRA for these kind of segfaults. Incidentally, zabbix_server (at the same version) used to work fine for us, and only after an upgrade of the base system (which meant a restart of the server process) led to the random segfaults occuring. |
Comments |
Comment by Alexei Vladishev [ 2012 Dec 23 ] |
Fixed in the development branch svn://svn.zabbix.com/branches/dev/ZBX-5981 |
Comment by Alexander Vladishev [ 2012 Dec 23 ] |
Successfully tested! |
Comment by Alexei Vladishev [ 2012 Dec 23 ] |
Fixed in version pre-pre-2.1.0 (trunk) and pre-2.0.5rc1 r32320. |