KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
While looking for ways to find the size of a file given a FILE* , I came across this article advising against it. Instead, it seems to encourage using file descriptors and fstat . However I was under the impression that fstat , open and file descriptors in general are not as portable (After a bit of searching, I've found something to this effect ). Is there a way to get the size of a file in ANSI C while keeping in line with the warnings in the article?
Tags (comma-separated)
Save Edits
Cancel