1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
--- sqlite-autoconf-3090200/sqlite3.c 2015-11-02 18:44:06.000000000 +0000
+++ sqlite-autoconf-3090200-patched/sqlite3.c 2015-11-30 20:23:29.014831341 +0000
@@ -26952,11 +26952,7 @@
** we are not running as root.
*/
static int posixFchown(int fd, uid_t uid, gid_t gid){
-#if OS_VXWORKS
return 0;
-#else
- return geteuid() ? 0 : fchown(fd,uid,gid);
-#endif
}
/* Forward reference */
@@ -30962,7 +30958,7 @@
** is owned by the same user that owns the original database. Otherwise,
** the original owner will not be able to connect.
*/
- osFchown(pShmNode->h, sStat.st_uid, sStat.st_gid);
+ //osFchown(pShmNode->h, sStat.st_uid, sStat.st_gid);
/* Check to see if another process is holding the dead-man switch.
** If not, truncate the file to zero length.
@@ -32443,9 +32439,9 @@
** journal or WAL file, set the ownership of the journal or WAL to be
** the same as the original database.
*/
- if( flags & (SQLITE_OPEN_WAL|SQLITE_OPEN_MAIN_JOURNAL) ){
- osFchown(fd, uid, gid);
- }
+ //if( flags & (SQLITE_OPEN_WAL|SQLITE_OPEN_MAIN_JOURNAL) ){
+ // osFchown(fd, uid, gid);
+ //}
}
assert( fd>=0 );
if( pOutFlags ){
|