Insert an entry into the index. A full copy (including the 'path' string) of the given 'source_entry' will be inserted on the index; if the index already contains an entry for the same path, the entry will be updated.
0 on success, otherwise an error code