commit | 0349bd9f14d252673a7a25767da4a80121aaaaf2 | [log] [tgz] |
---|---|---|
author | Anatol Pomazau <anatol@google.com> | Wed Jan 11 15:12:27 2012 -0800 |
committer | Anatol Pomazau <anatol@google.com> | Fri Feb 17 09:09:11 2012 -0800 |
tree | bf5e4d65aa227bac5d9bb42063e6b5a76fbf5d28 | |
parent | 879d01e18825e09c1196cc5bdeb6cbfddd92571a [diff] |
Pass file descriptor instead of file name Passing a file descriptor to make_ext4fs_internal() is more flexible. We can use tmpfile() to create a temporary file. tmpfile() is better than other solutions because it unlinks the file right after creating it, so closing fd effectively removes temp file. Thus we don't have to worry about large temp files accidently left on the filesystem in case of the program crash. Change-Id: Iba3758a0e13a898920d30d7fa5da696c22daa2b7