| 100 | } |
| 101 | |
| 102 | static struct tempfile *new_tempfile(void) |
| 103 | { |
| 104 | struct tempfile *tempfile = xmalloc(sizeof(*tempfile)); |
| 105 | tempfile->fd = -1; |
| 106 | tempfile->fp = NULL; |
| 107 | tempfile->owner = 0; |
| 108 | INIT_LIST_HEAD(&tempfile->list); |
| 109 | strbuf_init(&tempfile->filename, 0); |
| 110 | tempfile->directory = NULL; |
| 111 | return tempfile; |
| 112 | } |
| 113 | |
| 114 | static void activate_tempfile(struct tempfile *tempfile) |
| 115 | { |
no test coverage detected