push
This commit is contained in:
20
srcs/srcs_vm/check_args.c
Normal file
20
srcs/srcs_vm/check_args.c
Normal file
@@ -0,0 +1,20 @@
|
||||
/* ************************************************************************** */
|
||||
/* */
|
||||
/* ::: :::::::: */
|
||||
/* check_args.c :+: :+: :+: */
|
||||
/* +:+ +:+ +:+ */
|
||||
/* By: tmaze <tmaze@student.42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2019/05/22 13:34:11 by tmaze #+# #+# */
|
||||
/* Updated: 2019/05/22 13:41:20 by tmaze ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
#include "corewar.h"
|
||||
|
||||
int check_file(char *path)
|
||||
{
|
||||
char *ext;
|
||||
|
||||
return (path && (ext = ft_strrchr(path, '.')) && ft_strequ(ext, ".cor"));
|
||||
}
|
||||
Reference in New Issue
Block a user