Skip to content
Commit 9d66118b authored by Philip Withnall's avatar Philip Withnall 🚫 Committed by Stef Walter
Browse files

gcr: Fix failure case in gcr_secure_memory_try_realloc()

try_realloc() is explicitly documented as returning NULL in the failure
case, so remove an assertion that it can never happen. Similarly for
try_alloc().

This case can be hit if an application tries to allocate more than the
process’ RLIMIT_MEMLOCK limit (and the process is not privileged). This
limit is typically 64KiB, so not astronomical.

Add a test case.

https://bugzilla.gnome.org/show_bug.cgi?id=775685
parent 78e27105
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment