Guest_imported
New member
- Jan 1, 1970
- 0
Hi,
i have a question regarding using an array of structs in shared memory
my problem is that on some reason there isn't enough memory reserved
this is wat i do...
NUMBER 100
define a struct test
define MEMSEG sizeof(struct)*NUMBER
in main()
struct test record * record[NUMBER]
shmget(bla);
* record = ( struct test *)shmat(id, 0, 0);
when i loop through the number of records i only get
4 i expect a 100 could someone tell me what
i can do to correct this problem
thanks it's puzzeling me for some time
Robert
i have a question regarding using an array of structs in shared memory
my problem is that on some reason there isn't enough memory reserved
this is wat i do...
NUMBER 100
define a struct test
define MEMSEG sizeof(struct)*NUMBER
in main()
struct test record * record[NUMBER]
shmget(bla);
* record = ( struct test *)shmat(id, 0, 0);
when i loop through the number of records i only get
4 i expect a 100 could someone tell me what
i can do to correct this problem
thanks it's puzzeling me for some time
Robert