[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

GTK fe: multiselect handler and hw-detect/select-modules problem



Hi

at lines 645-647 in gtk.c we can find

defcount = strchoicesplit(question_getvalue(q, ""), defvals, count);
    if (defcount <= 0)
    	return DC_NOTOK;

here i suppose we check thet a multiselect question without options is not displayed, but i think this should be changed to

defcount = strchoicesplit(question_getvalue(q, ""), defvals, count);
    if (defcount < 0)
    	return DC_NOTOK;
    else if (defcount == 0)
    	return DC_OK;

to prevent multiselect questions with no options (that, although illogical, should be correctly handled ) from crashing the frontend. This is exactly the case of hw-detect/select-modules if there are noa vailable modules to be loaded.

Attilio



Reply to: