This commit is contained in:
2024-04-24 13:06:26 +02:00
parent 202c5e8811
commit 2cea45c05d
2 changed files with 20 additions and 3 deletions

View File

@ -6,7 +6,7 @@
/* By: marde-vr <marde-vr@42angouleme.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/02/18 18:29:20 by marde-vr #+# #+# */
/* Updated: 2024/04/23 12:49:46 by tomoron ### ########.fr */
/* Updated: 2024/04/24 13:03:32 by tomoron ### ########.fr */
/* */
/* ************************************************************************** */
@ -88,9 +88,10 @@ t_env *export_set_env(t_env *env, char *name, char *value, int append)
t_env *tmp;
tmp = env;
if (!value)
if (!value || !name)
{
free(name);
free(value);
ft_printf_fd(2, "minishell: malloc failed");
return (env);
}