diff options
author | Jerome Glisse <[email protected]> | 2011-03-28 17:45:31 -0400 |
---|---|---|
committer | Jerome Glisse <[email protected]> | 2011-03-30 17:03:00 -0400 |
commit | ebe304fa540f98d047382297f448fec692a67b8b (patch) | |
tree | 6b345b9880b3f2797b382fdd899e3147e418cb90 /src/gallium/auxiliary/draw | |
parent | dcad6fb670ccc533167d1ae360833989c1eb4823 (diff) |
gallium: list use inline function to avoid macro shot coming
Macro can lead to hard to debug list bugs. For instance consider
the following :
LIST_ADD(item, list->prev)
3 instruction of the macro became :
(list->prev)->next->prev = item
which is equivalent to :
list->prev = item
Thus list prev field changes and next instruction in the macro
(list->prev)->next = item
became :
item->next = item
And you endup with list corruption, other case lead to similar
list corruption. Inline function are not affected by this short
coming
Signed-off-by: Jerome Glisse <[email protected]>
Diffstat (limited to 'src/gallium/auxiliary/draw')
0 files changed, 0 insertions, 0 deletions