You should return an error here, e.g. `return (-1);`