Diff
Not logged in

Differences From Artifact [6f2a64a222]:

To Artifact [0ad3dd78ce]:


71
72
73
74
75
76
77



78

79
80
81
82
83
84
85
** for directories, devices, fifos, symlinks, etc.
*/
int file_isexe(const char *zFilename){
  struct stat buf;
  if( stat(zFilename, &buf)!=0 ){
    return 0;
  }



  return ((S_IXUSR|S_IXGRP|S_IXOTH)&buf.st_mode)!=0;

}

/*
** Set or clear the execute bit on a file.
*/
void file_setexe(const char *zFilename, int onoff){
#ifndef __MINGW32__







>
>
>

>







71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
** for directories, devices, fifos, symlinks, etc.
*/
int file_isexe(const char *zFilename){
  struct stat buf;
  if( stat(zFilename, &buf)!=0 ){
    return 0;
  }
#ifdef __MINGW32__
  return ((S_IXUSR)&buf.st_mode)!=0;
#else
  return ((S_IXUSR|S_IXGRP|S_IXOTH)&buf.st_mode)!=0;
#endif
}

/*
** Set or clear the execute bit on a file.
*/
void file_setexe(const char *zFilename, int onoff){
#ifndef __MINGW32__