Addressed review comments
This commit is contained in:
parent
3dd4ddddc8
commit
ab6126d55d
@ -1666,7 +1666,13 @@ vips_image_temp_name( char *name, int size )
|
|||||||
{
|
{
|
||||||
static int global_serial = 0;
|
static int global_serial = 0;
|
||||||
|
|
||||||
int serial = g_atomic_int_add( &global_serial, 1);
|
int serial =
|
||||||
|
#if GLIB_CHECK_VERSION( 2, 30, 0 )
|
||||||
|
g_atomic_int_add( &global_serial, 1);
|
||||||
|
#else
|
||||||
|
g_atomic_exchange_and_add( &global_serial, 1);
|
||||||
|
#endif
|
||||||
|
|
||||||
vips_snprintf( name, size, "temp-%d", serial );
|
vips_snprintf( name, size, "temp-%d", serial );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user