Fixed missing external parameter check which can lead at minimum to segmentation faults.