system/FileDescriptor: add method Tell()
This commit is contained in:
		| @@ -146,6 +146,11 @@ public: | |||||||
| 		return lseek(Get(), offset, SEEK_SET); | 		return lseek(Get(), offset, SEEK_SET); | ||||||
| 	} | 	} | ||||||
|  |  | ||||||
|  | 	gcc_pure | ||||||
|  | 	off_t Tell() const { | ||||||
|  | 		return lseek(Get(), 0, SEEK_CUR); | ||||||
|  | 	} | ||||||
|  |  | ||||||
| 	/** | 	/** | ||||||
| 	 * Returns the size of the file in bytes, or -1 on error. | 	 * Returns the size of the file in bytes, or -1 on error. | ||||||
| 	 */ | 	 */ | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Max Kellermann
					Max Kellermann