stuff
This commit is contained in:
parent
b698829eef
commit
ceb4ffdb55
@ -1011,24 +1011,26 @@ im__ftruncate( int fd, gint64 pos )
|
|||||||
return( 0 );
|
return( 0 );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* Like fwrite(), but returns non-zero on error and sets error message.
|
/* Like fwrite(), but returns non-zero on error and sets error message.
|
||||||
*/
|
*/
|
||||||
int
|
int
|
||||||
im__file_write( void *data, size_t size, size_t nmemb, FILE *stream )
|
im__file_write( void *data, size_t size, size_t nmemb, FILE *stream )
|
||||||
{
|
{
|
||||||
int n;
|
size_t n;
|
||||||
if( !data ) return( 0 );
|
|
||||||
|
if( !data )
|
||||||
|
return( 0 );
|
||||||
|
|
||||||
if( (n = fwrite( data, size, nmemb, stream )) != nmemb ) {
|
if( (n = fwrite( data, size, nmemb, stream )) != nmemb ) {
|
||||||
im_error( "im__file_write",
|
im_error( "im__file_write",
|
||||||
_( "writing error (%d out of %d blocks written) ... disc full?" ),
|
_( "writing error (%zd out of %zd blocks written) "
|
||||||
n, nmemb );
|
"... disc full?" ), n, nmemb );
|
||||||
return( -1 );
|
return( -1 );
|
||||||
}
|
}
|
||||||
|
|
||||||
return( 0 );
|
return( 0 );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* Check whether arch corresponds to native byte order.
|
/* Check whether arch corresponds to native byte order.
|
||||||
*/
|
*/
|
||||||
gboolean
|
gboolean
|
||||||
|
Loading…
x
Reference in New Issue
Block a user