summaryrefslogtreecommitdiff
path: root/command_handling.c
diff options
context:
space:
mode:
authorDominik Kaiser2024-04-13 14:52:57 +0200
committerDominik Kaiser2024-04-13 14:52:57 +0200
commitabc12d29679ae6049c9cacbf09a897529377d79c (patch)
tree5b82dec8bfb4332652ced35a44653ddc22c7aa89 /command_handling.c
parent2cef393801e18d68c762e293b5cef1194f77e078 (diff)
downloadpush_swap-abc12d29679ae6049c9cacbf09a897529377d79c.tar.gz
push_swap-abc12d29679ae6049c9cacbf09a897529377d79c.zip
Add command handling to makefile and setup main
Diffstat (limited to 'command_handling.c')
-rw-r--r--command_handling.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/command_handling.c b/command_handling.c
index e25f47c..b1fe85a 100644
--- a/command_handling.c
+++ b/command_handling.c
@@ -6,11 +6,10 @@
/* By: dkaiser <dkaiser@student.42heilbronn.de +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/04/13 14:38:47 by dkaiser #+# #+# */
-/* Updated: 2024/04/13 14:43:45 by dkaiser ### ########.fr */
+/* Updated: 2024/04/13 14:47:55 by dkaiser ### ########.fr */
/* */
/* ************************************************************************** */
-#include "libft/libft.h"
#include "push_swap.h"
static int add_cmd_to_queue(t_list **cmds, enum e_pscmd cmd)
@@ -21,6 +20,7 @@ static int add_cmd_to_queue(t_list **cmds, enum e_pscmd cmd)
ptr_cmd = malloc(sizeof(enum e_pscmd));
if (!ptr_cmd)
return (1);
+ *ptr_cmd = cmd;
new_elem = ft_lstnew(ptr_cmd);
if (!new_elem)
{