OLD | NEW |
1 /* | 1 /* |
2 ** 2007 June 22 | 2 ** 2007 June 22 |
3 ** | 3 ** |
4 ** The author disclaims copyright to this source code. In place of | 4 ** The author disclaims copyright to this source code. In place of |
5 ** a legal notice, here is a blessing: | 5 ** a legal notice, here is a blessing: |
6 ** | 6 ** |
7 ** May you do good and not evil. | 7 ** May you do good and not evil. |
8 ** May you find forgiveness for yourself and forgive others. | 8 ** May you find forgiveness for yourself and forgive others. |
9 ** May you share freely, never taking more than you give. | 9 ** May you share freely, never taking more than you give. |
10 ** | 10 ** |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 sqlite3_free(zErr); | 92 sqlite3_free(zErr); |
93 return; | 93 return; |
94 } | 94 } |
95 } | 95 } |
96 | 96 |
97 sqlite3_result_blob(context, (void *)&pPtr, sizeof(pPtr), SQLITE_TRANSIENT); | 97 sqlite3_result_blob(context, (void *)&pPtr, sizeof(pPtr), SQLITE_TRANSIENT); |
98 } | 98 } |
99 | 99 |
100 #ifdef SQLITE_TEST | 100 #ifdef SQLITE_TEST |
101 | 101 |
102 #include <tcl.h> | 102 #if defined(INCLUDE_SQLITE_TCL_H) |
| 103 # include "sqlite_tcl.h" |
| 104 #else |
| 105 # include "tcl.h" |
| 106 #endif |
103 #include <string.h> | 107 #include <string.h> |
104 | 108 |
105 /* | 109 /* |
106 ** Implementation of a special SQL scalar function for testing tokenizers | 110 ** Implementation of a special SQL scalar function for testing tokenizers |
107 ** designed to be used in concert with the Tcl testing framework. This | 111 ** designed to be used in concert with the Tcl testing framework. This |
108 ** function must be called with two arguments: | 112 ** function must be called with two arguments: |
109 ** | 113 ** |
110 ** SELECT <function-name>(<key-name>, <input-string>); | 114 ** SELECT <function-name>(<key-name>, <input-string>); |
111 ** SELECT <function-name>(<key-name>, <pointer>); | 115 ** SELECT <function-name>(<key-name>, <pointer>); |
112 ** | 116 ** |
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
362 || (rc = sqlite3_create_function(db, zTest2, 0, any, pdb, intTestFunc, 0, 0)) | 366 || (rc = sqlite3_create_function(db, zTest2, 0, any, pdb, intTestFunc, 0, 0)) |
363 #endif | 367 #endif |
364 ); | 368 ); |
365 | 369 |
366 sqlite3_free(zTest); | 370 sqlite3_free(zTest); |
367 sqlite3_free(zTest2); | 371 sqlite3_free(zTest2); |
368 return rc; | 372 return rc; |
369 } | 373 } |
370 | 374 |
371 #endif /* !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS2) */ | 375 #endif /* !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS2) */ |
OLD | NEW |