Skip to content

A function that reads a line from a file descriptor, returning one line at a time.

Notifications You must be signed in to change notification settings

ylam21/get_next_line

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

15 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

get_next_line

This project is part of the 42 Prague curriculum.
The goal of get_next_line is to implement a function that reads a line from a file descriptor, returning one line at a time.
It focuses on file I/O, dynamic memory management, and handling edge cases in C.

๐Ÿš€ Compilation & Usage

Since there is no Makefile, compile manually:

gcc -Wall -Wextra -Werror -D BUFFER_SIZE=42 get_next_line.c get_next_line_utils.c your_program.c -o a.out

BUFFER_SIZE must be defined at compile time.

You can change it to test different scenarios (e.g., 1, 32, 1000, etc.).

About

A function that reads a line from a file descriptor, returning one line at a time.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages