From 64a3e1d0f2a236601dc37fab75508067b8fb4a03 Mon Sep 17 00:00:00 2001 From: Frank Mori Hess Date: Tue, 20 Dec 2005 23:21:58 +0000 Subject: [PATCH] give an error message when user fails to provide firmware, and fix bug in test for whether firmware was provided. --- comedi/drivers/me_daq.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/comedi/drivers/me_daq.c b/comedi/drivers/me_daq.c index 58daeb6f..685c3ff7 100644 --- a/comedi/drivers/me_daq.c +++ b/comedi/drivers/me_daq.c @@ -820,8 +820,11 @@ found: aux_data = comedi_aux_data(it->options, 0); aux_len = it->options[COMEDI_DEVCONF_AUX_DATA_LENGTH]; - if(!aux_data || aux_len)return -EINVAL; - + if(!aux_data || aux_len < 1) + { + comedi_error("You must provide me2600 firmware using the --init-data option of comedi_config"); + return -EINVAL; + } me2600_xilinx_download(dev, aux_data, aux_len); } -- 2.26.2