wrong return value on succesful index fill