Add an extension to the index
an existing index object
the 4 character signature of the desired extension
the contents of the extension (not including the header)
the length of the data
0 (no error), GIT_EEXISTS (extension already present), or an error code