Hi Guys
I've just started using libzdb for a iOS (iPad) project. We use it because one software component has to be written in C (so, ... no use of CoreData or Object-C wrapper!).
I've encountered a problem SQLiteConnection.c. As far as i see it's not possible to have url escaped Path for sqlite (because the path for iOS Simulator has multiple " " (whitespaces)). I've changed line 80 to: const char *path = URL_unescape(URL_getPath(url));
Patch: *** vendor/libzdb-2.8.1/src/db/sqlite/SQLiteConnection.c 2011-02-15 01:13:35.000000000 +0100 --- vendor/libzdb-2.8.1/src/db/sqlite/SQLiteConnection_modified.c 2011-05-03 11:35:25.000000000 +0200 *************** *** 76,82 ****
static sqlite3 *doConnect(URL_T url, char **error) { sqlite3 *db; ! const char *path = URL_getPath(url); if (! path) { *error = Str_dup("no database specified in URL"); return NULL; --- 76,86 ----
static sqlite3 *doConnect(URL_T url, char **error) { sqlite3 *db; ! ! const char *path = URL_unescape(URL_getPath(url)); ! ! ! if (! path) { *error = Str_dup("no database specified in URL"); return NULL;
#################################
Maybe theres another solution. If not, maybe the patch will find his way to the main trunk.
-- Jonas
°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°° include7 AG Jonas Schnelli Grüngasse 10 CH-8004 Zürich Switzerland Office: +41 44 500 16 70
Skype: jonas.schnelli Mail: jonas.schnelli@include7.ch Web: www.include7.ch V-Card: www.include7.ch/js.vcf °°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°
ACHTUNG Bitte senden sie uns keine sensitiven Daten in unverschlüsselten E-Mails. Verwenden Sie hierzu folgenden Link: https://include7.ch/contact/secureform
°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°