Fix discovery error return without return value

openSUSE Build Service compiler noticed that one discovery
error path did not have a return value, so an appropriate
error is now being returned.

Signed-of-by: Lee Duncan <lduncan@suse.com>