file error
-
4. File I/O - library calls(3)HW & SW Interface/System Programming 2020. 5. 5. 16:52
# File offset 모든 파일은 read/write offset을 가지고 있으며, File offset은 해당 파일을 열었을 때 읽거나 쓸 시작 위치를 말한다. 파일을 읽거나 쓸때, 현재 offset의 위치를 그대로 사용하는 것을 sequential access라 하고, offset의 위치를 변경해서 사용하는 것을 random access라 한다. # Random access r/w offset을 변경하기위해 제공되는 함수(library calls)는 다음과 같다. 파일의 offset 위치 변경 int fseek(FILE *stream, long offset, int sopt) parameters stream: offset을 변경할 파일의 포인터 offset: SEEK options에 따른 offs..