Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 337 by [email protected]: Problems with C11's aligned_alloc?
https://code.google.com/p/address-sanitizer/issues/detail?id=337

What steps will reproduce the problem?
nick@fusrodah:/tmp$ cat openal-asan-trigger.cpp
#include <AL/al.h>
#include <AL/alc.h>

int main(){
ALCdevice* d = alcOpenDevice(0);
alcCloseDevice(d);
}
nick@fusrodah:/tmp$ clang++ -fsanitize=address openal-asan-trigger.cpp -lopenal
nick@fusrodah:/tmp$ ./a.out
=================================================================
==7999==ERROR: AddressSanitizer: attempting free on address which was not malloc()-ed: 0x0000034cc010 in thread T0
#0 0x465499 in __interceptor_free (/tmp/a.out+0x465499)
#1 0x7f905849e3b1 (/usr/lib/libopenal.so.1+0x2a3b1)
#2 0x47b8d2 in main (/tmp/a.out+0x47b8d2)
#3 0x7f9057292fff in __libc_start_main (/usr/lib/libc.so.6+0x1ffff)
#4 0x47b6fc in _start (/tmp/a.out+0x47b6fc)

AddressSanitizer can not describe address in more detail (wild memory access suspected).
SUMMARY: AddressSanitizer: bad-free ??:0 __interceptor_free
==7999==ABORTING

What is the expected output? What do you see instead?
No error from ASAN, the thing is properly allocated.

What version of the product are you using? On what operating system?
Asan from clang-3.4 on Arch linux.

Please provide any additional information below.
Arch Linux bug report: https://bugs.archlinux.org/task/41651?
OpenAL bug report (with the conclusion that it doesn't error when malloc is used instead of alligned_alloc): https://github.com/kcat/openal-soft/issues/1





--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups 
"address-sanitizer" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to