mirror of
https://github.com/DavidGailleton/42-Push_Swap.git
synced 2026-01-27 08:41:58 +00:00
Bench algo working
This commit is contained in:
20
secure_write.c
Normal file
20
secure_write.c
Normal file
@@ -0,0 +1,20 @@
|
||||
/* ************************************************************************** */
|
||||
/* */
|
||||
/* ::: :::::::: */
|
||||
/* secure_write.c :+: :+: :+: */
|
||||
/* +:+ +:+ +:+ */
|
||||
/* By: dgaillet <dgaillet@student.42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2026/01/08 14:30:38 by dgaillet #+# #+# */
|
||||
/* Updated: 2026/01/08 14:32:19 by dgaillet ### ########lyon.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
#include <unistd.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
void secure_write(int fd, char *str, int len)
|
||||
{
|
||||
if (write(fd, str, len) < 0)
|
||||
exit ( EXIT_FAILURE );
|
||||
}
|
||||
Reference in New Issue
Block a user