Normed stuff
This commit is contained in:
parent
8146ed2176
commit
f925aea552
9 changed files with 23 additions and 25 deletions
|
|
@ -27,7 +27,8 @@ t_fd *dup_fd(t_fd *fd)
|
|||
return (NULL);
|
||||
tmp = dup(fd->fd);
|
||||
if (tmp == -1)
|
||||
return (printf("There was an error while duping the fd %d `%s`\n", fd->fd, fd->name), NULL);
|
||||
return (printf("There was an error while duping the "\
|
||||
"fd %d `%s`\n", fd->fd, fd->name), NULL);
|
||||
slot->ty = SLOT_FD;
|
||||
slot->slot.fd.fd = tmp;
|
||||
slot->slot.fd.perms = fd->perms;
|
||||
|
|
|
|||
|
|
@ -21,10 +21,6 @@
|
|||
#include <stdio.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#ifdef static
|
||||
# undef static
|
||||
#endif
|
||||
|
||||
t_fd_array *get_fd_arrays(void)
|
||||
{
|
||||
static t_fd_array val = {};
|
||||
|
|
|
|||
|
|
@ -21,10 +21,6 @@
|
|||
#include <stdio.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#ifdef static
|
||||
# undef static
|
||||
#endif
|
||||
|
||||
t_fd *get_stdin(void)
|
||||
{
|
||||
t_fd *out;
|
||||
|
|
|
|||
|
|
@ -20,10 +20,6 @@
|
|||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#ifdef static
|
||||
#undef static
|
||||
#endif
|
||||
|
||||
static t_static_buffer *get_next_line_buffer(int fd)
|
||||
{
|
||||
t_usize index;
|
||||
|
|
|
|||
|
|
@ -17,10 +17,6 @@
|
|||
#include "me/types.h"
|
||||
#include <stdio.h>
|
||||
|
||||
#ifdef static
|
||||
# undef static
|
||||
#endif
|
||||
|
||||
t_allocator *global_allocator(void)
|
||||
{
|
||||
static t_allocator global_alloc = {};
|
||||
|
|
|
|||
|
|
@ -18,8 +18,18 @@
|
|||
# define BASE_PATH "/no_base_path_defined/"
|
||||
#endif
|
||||
|
||||
#if defined(PRINT_BACKTRACE) || defined(BACKTRACE_DEEP)
|
||||
// #if true // TO_REMOVE
|
||||
#ifdef PRINT_BACKTRACE
|
||||
# ifndef _PRINT_BACKTRACE
|
||||
# define _PRINT_BACKTRACE
|
||||
# endif
|
||||
#endif
|
||||
#ifdef BACKTRACE_DEEP
|
||||
# ifndef _PRINT_BACKTRACE
|
||||
# define _PRINT_BACKTRACE
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifdef _PRINT_BACKTRACE
|
||||
# ifndef BACKTRACE_DEEP
|
||||
# define BACKTRACE_DEEP 256
|
||||
# endif
|
||||
|
|
|
|||
|
|
@ -15,7 +15,14 @@
|
|||
|
||||
# define _GNU_SOURCE
|
||||
|
||||
# if defined(PRINT_BACKTRACE) || defined(BACKTRACE_DEEP)
|
||||
# ifdef PRINT_BACKTRACE
|
||||
# include <dlfcn.h>
|
||||
# include <execinfo.h>
|
||||
# include <link.h>
|
||||
# include <stdio.h>
|
||||
# include <stdlib.h>
|
||||
# endif
|
||||
# ifdef BACKTRACE_DEEP
|
||||
# include <dlfcn.h>
|
||||
# include <execinfo.h>
|
||||
# include <link.h>
|
||||
|
|
|
|||
|
|
@ -17,10 +17,6 @@
|
|||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#ifdef static
|
||||
# undef static
|
||||
#endif
|
||||
|
||||
t_matcher_list *get_matchers(void)
|
||||
{
|
||||
static t_matcher_list printf_matchers = (t_matcher_list){
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue