templates / branches--on commit refs.c: release file descriptor on error return (9d33f7c)
   1: this is just to ensure the directory exists.