• Jinoh Kang's avatar
    gdiplus: Replace GpImage's busy flag with SRWLOCK. · 72c0c88f
    Jinoh Kang authored
    Today, the image_unlock() helper function has a data race due to
    non-atomic write to GpImage's 'busy' flag which is accessible by other
    threads.  Also, it lacks a release fence, which means that other threads
    can observe the unlocked (busy = 0) state too early when the current
    thread unlocks the image; specifically, the write to the 'busy' field of
    the GpImage can be reordered before the last read/write to any other
    fields of the same GpImage.
    
    Fix this by replacing the 'busy' field of GpImage with SRWLOCK.
    72c0c88f
Name
Last commit
Last update
..
tests Loading commit data...
Makefile.in Loading commit data...
brush.c Loading commit data...
customlinecap.c Loading commit data...
font.c Loading commit data...
gdiplus.c Loading commit data...
gdiplus.manifest Loading commit data...
gdiplus.rc Loading commit data...
gdiplus.spec Loading commit data...
gdiplus11.manifest Loading commit data...
gdiplus_private.h Loading commit data...
graphics.c Loading commit data...
graphicspath.c Loading commit data...
image.c Loading commit data...
imageattributes.c Loading commit data...
matrix.c Loading commit data...
metafile.c Loading commit data...
pathiterator.c Loading commit data...
pen.c Loading commit data...
region.c Loading commit data...
stringformat.c Loading commit data...