Skip to content

C function that returns a line ending with a newline, read from a file descriptor.

License

Notifications You must be signed in to change notification settings

iker-gonzalez/get-next-line

Repository files navigation

42cursus' get_next_line

Development repo for 42cursus' get_next_line project
For further information about 42cursus and its projects, please refer to 42cursus repo.

GitHub code size in bytes Number of lines of code Code language count GitHub top language GitHub last commit


🗣️ About

The aim of this project is to make you code a function that returns a line ending with a newline, read from a file descriptor.

For detailed information, refer to the subject of this project.

🚀 This project consists of coding a function that returns one line at a time from a text file.

🛠️ Usage

Requirements

The function is written in C language and thus needs the gcc compiler and some standard C libraries to run.

Instructions

1. Using it in your code

To use the function in your code, simply include its header:

#include "get_next_line.h"

and, when compiling your code, add the source files and the required flag:

get_next_line.c get_next_line_utils.c -D BUFFER_SIZE=<size>

If you're on Linux, you may as well need the following flags:

-D ARG_MAX="sysconf(_SC_ARG_MAX)" -D OPEN_MAX=1024

Testing

You can use any of this third-party testers to test the project:

About

C function that returns a line ending with a newline, read from a file descriptor.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages