# HG changeset patch # User Vladimir S. FONOV # Date 1334782812 14400 # Node ID 9944c7923d5b9b1a9d995e8492655971f6125742 # Parent 99d4a3bb68dfede5bcc5fb5e6afd0d8f7a72ef67 Fixed a bug causing crash when output pixel obj type in ascii format diff --git a/volume_io/Prog_utils/files.c b/volume_io/Prog_utils/files.c --- a/volume_io/Prog_utils/files.c +++ b/volume_io/Prog_utils/files.c @@ -2521,7 +2521,7 @@ } else { - if( fprintf( file, "%d", (int) *c ) != 1 ) + if( fprintf( file, "%d", (int) *c ) < 0 ) { print_error( "Error outputting unsigned char. " ); print_system_error();