Bug fix when there is no service in embedded devices
When a device with embedded devices (like IGD) when created and one of the embedded devices did not have any service, there was a Segmentation Fault (see SF Tracker [ 2688125 ]).
This commit is contained in:

committed by
Marcelo Roberto Jimenez

parent
c33b11d09f
commit
ab54cb3dc5
@@ -913,8 +913,10 @@ getServiceList( IXML_Node * node,
|
||||
( *end ) = current;
|
||||
|
||||
return head;
|
||||
} else
|
||||
} else {
|
||||
( *end ) = NULL;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -960,7 +962,8 @@ getAllServiceList( IXML_Node * node,
|
||||
if( head ) {
|
||||
end->next =
|
||||
getServiceList( currentDevice, &next_end, URLBase );
|
||||
end = next_end;
|
||||
if ( next_end )
|
||||
end = next_end;
|
||||
} else
|
||||
head = getServiceList( currentDevice, &end, URLBase );
|
||||
|
||||
|
Reference in New Issue
Block a user