Issue Details (XML | Word | Printable)

Key: CORE-1983
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Alexander Peshkov
Reporter: Alexander Peshkov
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Firebird Core

Out of memory condition in OS causes AV

Created: 08/Jul/08 03:53 AM   Updated: 26/Jan/09 09:23 AM
Return to search
Component/s: Engine
Affects Version/s: 2.0.0, 2.0.1, 2.1 Alpha 1, 2.1 Beta 1, 2.0.2, 2.0.3, 2.1 Beta 2, 2.1 RC1, 2.5 Initial, 2.1 RC2, 2.1.0, 2.0.4, 2.5 Alpha 1, 2.1.1
Fix Version/s: 2.0.5, 2.1.2, 2.5 Beta 1

Time Tracking:
Not Specified

Environment: All posix except Solaris

Target: 2.5 Beta 1, 2.1.2 and 2.0.5
Planning Status: Unspecified


 Description  « Hide
mmap() call returns MAP_FAILED (-1) in case of any error, including out of memory condition.
In alloc.cpp:external_alloc() value, returned by MMAP, is returned directly (except Solaris), no matter of the fact that caller expects NULL in case of allocation error, not -1. Therefore (void*)(-1) is used as a normally allocated memory block, definitely causing segfault at the moment of first use.

 All   Comments   Work Log   Change History   Version Control      Sort Order: Ascending order - Click to sort in descending order
The cvs commits can not be displayed for repository Firebird at the moment since the log has not yet been parsed. The log will be parsed the next time the VcsService runs. If you have administrators privileges you can hasten the next time the service will run in the service section of the Administration pages.