Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | move os2FullPathname() so that it can be used in os2Open() directly (CVS 5495) |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
2455e45484eff85bf9fd78dadd1e934f |
User & Date: | pweilbacher 2008-07-29 18:35:54.000 |
Context
2008-07-29
| ||
18:38 | recursively call os2Open() with the incoming VFS pointer, in case it gets used in the future (CVS 5496) (check-in: 6eac49f046 user: pweilbacher tags: trunk) | |
18:35 | move os2FullPathname() so that it can be used in os2Open() directly (CVS 5495) (check-in: 2455e45484 user: pweilbacher tags: trunk) | |
14:29 | Enhancements to the pagecache malloc test configuration. Changes to the speed test scripts to use the new test enhancements. (CVS 5494) (check-in: 0ce39c21f3 user: drh tags: trunk) | |
Changes
Changes to src/os_os2.c.
︙ | ︙ | |||
8 9 10 11 12 13 14 | ** May you find forgiveness for yourself and forgive others. ** May you share freely, never taking more than you give. ** ****************************************************************************** ** ** This file contains code that is specific to OS/2. ** | | | 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | ** May you find forgiveness for yourself and forgive others. ** May you share freely, never taking more than you give. ** ****************************************************************************** ** ** This file contains code that is specific to OS/2. ** ** $Id: os_os2.c,v 1.53 2008/07/29 18:35:54 pweilbacher Exp $ */ #include "sqliteInt.h" #if SQLITE_OS_OS2 /* |
︙ | ︙ | |||
706 707 708 709 710 711 712 713 714 715 716 717 718 719 | zBuf[j] = (char)zChars[ ((unsigned char)zBuf[j])%(sizeof(zChars)-1) ]; } zBuf[j] = 0; OSTRACE2( "TEMP FILENAME: %s\n", zBuf ); return SQLITE_OK; } /* ** Open a file. */ static int os2Open( sqlite3_vfs *pVfs, /* Not used */ const char *zName, /* Name of the file */ | > > > > > > > > > > > > > > > > > > > > > > > > | 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 | zBuf[j] = (char)zChars[ ((unsigned char)zBuf[j])%(sizeof(zChars)-1) ]; } zBuf[j] = 0; OSTRACE2( "TEMP FILENAME: %s\n", zBuf ); return SQLITE_OK; } /* ** Turn a relative pathname into a full pathname. Write the full ** pathname into zFull[]. zFull[] will be at least pVfs->mxPathname ** bytes in size. */ static int os2FullPathname( sqlite3_vfs *pVfs, /* Pointer to vfs object */ const char *zRelative, /* Possibly relative input path */ int nFull, /* Size of output buffer in bytes */ char *zFull /* Output buffer */ ){ char *zRelativeCp = convertUtf8PathToCp( zRelative ); char zFullCp[CCHMAXPATH] = "\0"; char *zFullUTF; APIRET rc = DosQueryPathInfo( zRelativeCp, FIL_QUERYFULLNAME, zFullCp, CCHMAXPATH ); free( zRelativeCp ); zFullUTF = convertCpPathToUtf8( zFullCp ); sqlite3_snprintf( nFull, zFull, zFullUTF ); free( zFullUTF ); return rc == NO_ERROR ? SQLITE_OK : SQLITE_IOERR; } /* ** Open a file. */ static int os2Open( sqlite3_vfs *pVfs, /* Not used */ const char *zName, /* Name of the file */ |
︙ | ︙ | |||
775 776 777 778 779 780 781 | } if( flags & (SQLITE_OPEN_TEMP_DB | SQLITE_OPEN_TEMP_JOURNAL | SQLITE_OPEN_SUBJOURNAL) ){ char pathUtf8[CCHMAXPATH]; /*ulFileAttribute = FILE_HIDDEN; //for debugging, we want to make sure it is deleted*/ ulFileAttribute = FILE_NORMAL; | | | 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 | } if( flags & (SQLITE_OPEN_TEMP_DB | SQLITE_OPEN_TEMP_JOURNAL | SQLITE_OPEN_SUBJOURNAL) ){ char pathUtf8[CCHMAXPATH]; /*ulFileAttribute = FILE_HIDDEN; //for debugging, we want to make sure it is deleted*/ ulFileAttribute = FILE_NORMAL; os2FullPathname( pVfs, zName, CCHMAXPATH, pathUtf8 ); pFile->pathToDel = convertUtf8PathToCp( pathUtf8 ); OSTRACE1( "OPEN hidden/delete on close file attributes\n" ); }else{ ulFileAttribute = FILE_ARCHIVED | FILE_NORMAL; pFile->pathToDel = NULL; OSTRACE1( "OPEN normal file attribute\n" ); } |
︙ | ︙ | |||
880 881 882 883 884 885 886 | assert( !"Invalid flags argument" ); } *pOut = rc; return SQLITE_OK; } | < < < < < < < < < < < < < < < < < < < < < < < | 904 905 906 907 908 909 910 911 912 913 914 915 916 917 | assert( !"Invalid flags argument" ); } *pOut = rc; return SQLITE_OK; } #ifndef SQLITE_OMIT_LOAD_EXTENSION /* ** Interfaces for opening a shared library, finding entry points ** within the shared library, and closing the shared library. */ /* ** Interfaces for opening a shared library, finding entry points |
︙ | ︙ |