File tree Expand file tree Collapse file tree 2 files changed +6
-10
lines changed Expand file tree Collapse file tree 2 files changed +6
-10
lines changed Original file line number Diff line number Diff line change @@ -845,11 +845,9 @@ static MagickBooleanType ClonePixelCacheOnDisk(
845
845
static inline int GetCacheNumberThreads (const CacheInfo * source ,
846
846
const CacheInfo * destination ,const size_t chunk ,const int factor )
847
847
{
848
- int
849
- max_threads = GetMagickResourceLimit (ThreadResource ),
850
- number_threads = 1 ;
851
-
852
848
size_t
849
+ max_threads = (size_t ) GetMagickResourceLimit (ThreadResource ),
850
+ number_threads = 1 ,
853
851
workload_factor = 64UL << factor ;
854
852
855
853
/*
@@ -864,7 +862,7 @@ static inline int GetCacheNumberThreads(const CacheInfo *source,
864
862
if (((source -> type != MemoryCache ) && (source -> type != MapCache )) ||
865
863
((destination -> type != MemoryCache ) && (destination -> type != MapCache )))
866
864
number_threads = MagickMin (number_threads ,4 );
867
- return (number_threads );
865
+ return (( int ) number_threads );
868
866
}
869
867
870
868
static MagickBooleanType ClonePixelCacheRepository (
Original file line number Diff line number Diff line change @@ -54,11 +54,9 @@ static inline int GetMagickNumberThreads(const Image *source,
54
54
destination_type = (CacheType ) GetImagePixelCacheType (destination ),
55
55
source_type = (CacheType ) GetImagePixelCacheType (source );
56
56
57
- int
58
- max_threads = GetMagickResourceLimit (ThreadResource ),
59
- number_threads = 1 ;
60
-
61
57
size_t
58
+ max_threads = (size_t ) GetMagickResourceLimit (ThreadResource ),
59
+ number_threads = 1 ,
62
60
workload_factor = 64UL << factor ;
63
61
64
62
/*
@@ -73,7 +71,7 @@ static inline int GetMagickNumberThreads(const Image *source,
73
71
if (((source_type != MemoryCache ) && (source_type != MapCache )) ||
74
72
((destination_type != MemoryCache ) && (destination_type != MapCache )))
75
73
number_threads = MagickMin (number_threads ,4 );
76
- return (number_threads );
74
+ return (( int ) number_threads );
77
75
}
78
76
79
77
static inline MagickThreadType GetMagickThreadId (void )
You can’t perform that action at this time.
0 commit comments