mirror of
https://github.com/ibm-s390-linux/s390-tools.git
synced 2026-08-05 02:14:52 +00:00
osasnmpd: remove unused code, improve readability
Remove unused code because query_OSA_EXP does actually never return -1. So make its return value unsigned and remove all checks for negative return values. Signed-off-by: Karsten Graul <kgraul@linux.ibm.com> Signed-off-by: Jan Höppner <hoeppner@linux.ibm.com>
This commit is contained in:
committed by
Jan Höppner
parent
66ed1727f9
commit
ff2a403bd2
@@ -85,15 +85,7 @@ void init_ibmOSAMib(void) {
|
||||
|
||||
/* query OSA-E device driver for OSA-E devices and mark them in IF-MIB interface list */
|
||||
osaexp_num = query_OSA_EXP ( &if_list, ifNumber );
|
||||
if ( osaexp_num < 0 )
|
||||
{
|
||||
fprintf( stderr, "init_ibmOSAMib(): "
|
||||
"OSA-E device driver query interface ioctl() failed\n"
|
||||
"check agent log file for more details\n"
|
||||
"Cannot start subagent...exiting...\n");
|
||||
exit(1);
|
||||
}
|
||||
else if ( osaexp_num == 0 )
|
||||
if ( osaexp_num == 0 )
|
||||
{
|
||||
get_time( time_buf );
|
||||
snmp_log( LOG_ERR, "%s init_ibmOSAMib(): none of the %d interfaces is a real "
|
||||
|
||||
Reference in New Issue
Block a user