summaryrefslogblamecommitdiff
path: root/src/stat/stat.c
blob: 0bec9d6fa972e7dab9c1611a867214fa85f28917 (plain) (tree)
1
2
3
4
5
6
7
8
                     
                  
                    
 
                                                              
 
               
                                            


                                                            

 
                         
#include <sys/stat.h>
#include <fcntl.h>
#include "syscall.h"

int stat(const char *restrict path, struct stat *restrict buf)
{
#ifdef SYS_stat
	return syscall(SYS_stat, path, buf);
#else
	return syscall(SYS_fstatat, AT_FDCWD, path, buf, 0);
#endif
}

weak_alias(stat, stat64);