From: Frank Mori Hess Date: Fri, 14 Mar 2008 17:52:20 +0000 (+0000) Subject: Allow comedi_cleanup_calibration to accept a NULL argument. X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=e0b0b89338bb17e69b53aa77dde4019682b18177;p=comedilib.git Allow comedi_cleanup_calibration to accept a NULL argument. --- diff --git a/lib/calib_yacc.y b/lib/calib_yacc.y index f8725c7..5c256a8 100644 --- a/lib/calib_yacc.y +++ b/lib/calib_yacc.y @@ -263,6 +263,7 @@ static comedi_calibration_t* alloc_calib_parse( void ) EXPORT_ALIAS_DEFAULT(_comedi_cleanup_calibration,comedi_cleanup_calibration,0.7.20); extern void _comedi_cleanup_calibration( comedi_calibration_t *file_contents ) { + if(file_contents == NULL) return; if( file_contents->driver_name ) { free( file_contents->driver_name );