coverity#1242459 Identical code for different branches

on the somewhat dubious logic of matching the otherwise
near-identical duplicate logic later on

Change-Id: Ic029cafbf2fa2a1fd3cf78464d58977f90bbc418