Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

shmctl interceptor does not work in 32-bit mode #250

Closed
ramosian-glider opened this issue Aug 31, 2015 · 5 comments
Closed

shmctl interceptor does not work in 32-bit mode #250

ramosian-glider opened this issue Aug 31, 2015 · 5 comments

Comments

@ramosian-glider
Copy link
Member

Originally reported on Google Code with ID 250

% cat shm.cc 
#include <stdio.h>
#include <sys/ipc.h>
#include <sys/shm.h>
#include <assert.h>

int main() {
  int id = shmget(IPC_PRIVATE, 4096, 0644 | IPC_CREAT);
  assert(id > -1);
  struct shmid_ds ds;
  int res = shmctl(id, IPC_STAT, &ds);
  assert(res > -1);
  printf("shm_segsz: %zd\n", ds.shm_segsz);
}
% clang -fsanitize=address shm.cc && ./a.out 
shm_segsz: 4096
% clang shm.cc && ./a.out 
shm_segsz: 4096
% clang -m32 shm.cc && ./a.out 
shm_segsz: 4096
% clang -m32 -fsanitize=address shm.cc && ./a.out 
shm_segsz: 135004160
% 

Disabling the interceptor helps, I am going to disable it for 32-bit

Reported by konstantin.s.serebryany on 2013-11-29 14:04:45

@ramosian-glider
Copy link
Member Author

Disabled in http://llvm.org/viewvc/llvm-project?view=revision&revision=195958

Reported by konstantin.s.serebryany on 2013-11-29 14:14:39

@ramosian-glider
Copy link
Member Author

FYI: this still fails despite  http://llvm.org/viewvc/llvm-project?rev=200468&view=rev

Reported by konstantin.s.serebryany on 2014-01-31 09:07:14

@ramosian-glider
Copy link
Member Author

Reported by ramosian.glider on 2015-07-30 09:05:31

  • Labels added: ProjectAddressSanitizer

@ramosian-glider
Copy link
Member Author

Adding Project:AddressSanitizer as part of GitHub migration.

Reported by ramosian.glider on 2015-07-30 09:06:56

@kcc
Copy link
Contributor

kcc commented Dec 1, 2015

Fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants