shm: Make sure the zero-sized array is always last in the struct

https://bugzilla.gnome.org/show_bug.cgi?id=696681
This commit is contained in:
Olivier Crête 2013-03-28 14:36:16 -04:00
parent c42ac5b450
commit 6e9ff0a160

View file

@ -115,10 +115,11 @@ struct _ShmBuffer
ShmBuffer *next; ShmBuffer *next;
int num_clients;
int clients[0];
void *tag; void *tag;
int num_clients;
/* This must ALWAYS stay last in the struct */
int clients[0];
}; };