Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Evergreen:11.1:Test
ImageMagick
ImageMagick-6.4.3.6-race.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File ImageMagick-6.4.3.6-race.patch of Package ImageMagick
--- magick/cache.c +++ magick/cache.c @@ -4325,44 +4325,35 @@ MagickExport MagickBooleanType SyncImagePixelCache(Image *image) { - CacheInfo - *cache_info; - MagickBooleanType status; + RectangleInfo + geometry; + assert(image != (Image *) NULL); assert(image->signature == MagickSignature); if (image->debug != MagickFalse) (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); assert(image->cache != (Cache) NULL); status=MagickTrue; - cache_info=(CacheInfo *) image->cache; - if ((cache_info->reference_count > 1) || - (IsCacheSynchronized(image) == MagickFalse)) - { - AcquireSemaphoreInfo(&cache_info->semaphore); - if ((cache_info->reference_count > 1) || - (IsCacheSynchronized(image) == MagickFalse)) - { - status=ModifyCache(image); - if (status != MagickFalse) - status=SyncCache(image); - if (status != MagickFalse) - { - RectangleInfo - region; - - region.x=0; - region.y=0; - region.width=image->columns; - region.height=1; - if (SetNexus(image,®ion,0) == (PixelPacket *) NULL) - status=MagickFalse; - } - } - RelinquishSemaphoreInfo(cache_info->semaphore); - } + AcquireSemaphoreInfo(&image->semaphore); +#if !defined(MAGICKCORE_HAVE_PTHREAD) + #pragma omp critical (pixel_cache) + { +#endif + if (ModifyCache(image) == MagickFalse) + status=MagickFalse; + if (SyncCache(image) == MagickFalse) + status=MagickFalse; + SetGeometry(image,&geometry); + geometry.height=1; + if (SetNexus(image,&geometry,0) == (PixelPacket *) NULL) + status=MagickFalse; +#if !defined(MAGICKCORE_HAVE_PTHREAD) + } +#endif + RelinquishSemaphoreInfo(image->semaphore); return(status); }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor