8000 GitHub - ulsgks/get_next_line: A GNL without ANY leaks??? YES, it's possible! Francinette strict mode approved.
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

ulsgks/get_next_line

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A Strict Get Next Line

Did this project help you? Give it a 🌟!

📃 General information

Version: 10. Bonus included.

⚙️ Implementation details

I spent a lot of time on this project to make it completely leak-free, especially in situations where malloc() fails. The challenge was to send the error back to the main function and free the memory properly.
The _utils file provides an unchanged or slightly modified libft function (in this case the _gnl suffix is added).
Bonus files are copies of the base implementation with small modifications to handle multiple files and related includes.

✨ Versions

The version compiled by the Makefile is a more secure version made to be used in other projects as an independent library. The submitted version is the src_original directory.
Change logs:

  • get_next_line returns a status and puts the line in a buffer. It allows you to make the difference between an error and the end of a file.
  • Makefile, include, and build/ directory.
  • Only bonus version.

🎉 Testing

Tested by moulinette (125%) and francinette in strict mode.

About

A GNL without ANY leaks??? YES, it's possible! Francinette strict mode approved.

Topics

Resources

Stars

Watchers

Forks

0