• Stefan Knoblich's avatar
    [FreeTDM] Fix segfault in ftdm_analog_configure_span() on startup. · 02b29263
    Stefan Knoblich 提交于
    Using ftdm_log_chan() in ftdm_analog_configure_span() is a bad idea,
    since the span won't have any channels assigned.
    
    This bug powered by declaring all variables at the top of the function,
    even if they are used in an if branch at the end.
    
    A C99'ish:
    
    	if (callwaiting) {
    		for (unsigned int i = 1; i <= span->span->chan_count; i++) {
    			/* ... */
    		}
    	}
    
    would have alerted the developer adding the log statement.
    But since we can't have nice things (thanks MSVC for not supporting C99!)
    </rant>
    Signed-off-by: 's avatarStefan Knoblich <s.knoblich@axsentis.de>
    02b29263
名称
最后提交
最后更新
..
ftdm_analog.h 正在载入提交数据...
ftmod_analog.2008.vcproj 正在载入提交数据...
ftmod_analog.2010.vcxproj 正在载入提交数据...
ftmod_analog.2010.vcxproj.filters 正在载入提交数据...
ftmod_analog.c 正在载入提交数据...