mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-11 01:42:22 +03:00
Documentation updates in preparation for the release of version 3.0.0. (CVS 1613)
FossilOrigin-Name: 9fb29f7331254b601b71f0fe7d77f91915272dc7
This commit is contained in:
@@ -607,17 +607,22 @@ int sqlite3OsSeek(OsFile *id, off_t offset){
|
||||
int sqlite3OsSync(OsFile *id){
|
||||
SimulateIOError(SQLITE_IOERR);
|
||||
TRACE2("SYNC %-3d\n", id->h);
|
||||
{
|
||||
off_t sz;
|
||||
sqlite3OsFileSize(id, &sz);
|
||||
fprintf(stderr,"SYNC %d size=%lld... ", id->h, sz);
|
||||
}
|
||||
if( fsync(id->h) ){
|
||||
return SQLITE_IOERR;
|
||||
}else{
|
||||
if( id->dirfd>=0 ){
|
||||
TRACE2("DIRSYNC %-3d\n", id->dirfd);
|
||||
fsync(id->dirfd);
|
||||
close(id->dirfd); /* Only need to sync once, so close the directory */
|
||||
id->dirfd = -1; /* when we are done. */
|
||||
}
|
||||
return SQLITE_OK;
|
||||
}
|
||||
if( id->dirfd>=0 ){
|
||||
TRACE2("DIRSYNC %-3d\n", id->dirfd);
|
||||
fsync(id->dirfd);
|
||||
close(id->dirfd); /* Only need to sync once, so close the directory */
|
||||
id->dirfd = -1; /* when we are done. */
|
||||
}
|
||||
fprintf(stderr,"DONE\n");
|
||||
return SQLITE_OK;
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
*************************************************************************
|
||||
** This file contains code used to implement the PRAGMA command.
|
||||
**
|
||||
** $Id: pragma.c,v 1.45 2004/06/16 12:02:43 danielk1977 Exp $
|
||||
** $Id: pragma.c,v 1.46 2004/06/17 19:04:17 drh Exp $
|
||||
*/
|
||||
#include "sqliteInt.h"
|
||||
#include <ctype.h>
|
||||
@@ -124,10 +124,12 @@ static int flagPragma(Parse *pParse, const char *zLeft, const char *zRight){
|
||||
{ "vdbe_trace", SQLITE_VdbeTrace },
|
||||
{ "sql_trace", SQLITE_SqlTrace },
|
||||
{ "vdbe_listing", SQLITE_VdbeListing },
|
||||
#if 1 /* FIX ME: Remove the following pragmas */
|
||||
{ "full_column_names", SQLITE_FullColNames },
|
||||
{ "short_column_names", SQLITE_ShortColNames },
|
||||
{ "count_changes", SQLITE_CountRows },
|
||||
{ "empty_result_callbacks", SQLITE_NullCallback },
|
||||
#endif
|
||||
};
|
||||
int i;
|
||||
for(i=0; i<sizeof(aPragma)/sizeof(aPragma[0]); i++){
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
** This header file defines the interface that the SQLite library
|
||||
** presents to client programs.
|
||||
**
|
||||
** @(#) $Id: sqlite.h.in,v 1.101 2004/06/12 09:25:20 danielk1977 Exp $
|
||||
** @(#) $Id: sqlite.h.in,v 1.102 2004/06/17 19:04:17 drh Exp $
|
||||
*/
|
||||
#ifndef _SQLITE_H_
|
||||
#define _SQLITE_H_
|
||||
@@ -950,6 +950,16 @@ void *sqlite3_user_data(sqlite3_context*);
|
||||
void *sqlite3_get_auxdata(sqlite3_context*, int);
|
||||
void sqlite3_set_auxdata(sqlite3_context*, int, void*, void (*)(void*));
|
||||
|
||||
|
||||
/*
|
||||
** These are special value for the destructor that is passed in as the
|
||||
** final argument to routines like sqlite3_result_blob(). If the destructor
|
||||
** argument is SQLITE_STATIC, it means that the content pointer is constant
|
||||
** and will never change. It does not need to be destroyed. The
|
||||
** SQLITE_TRANSIENT value means that the content will likely change in
|
||||
** the near future and that SQLite should make its own private copy of
|
||||
** the content before returning.
|
||||
*/
|
||||
#define SQLITE_STATIC ((void(*)(void *))0)
|
||||
#define SQLITE_TRANSIENT ((void(*)(void *))-1)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user