Floris Bruynooghe
f8d428c308
Make the SQLite struct opaque
...
With the API changes already done, notably .is_open(), the
implementation of the sqlite can and should now be private.
This also doesn't need to be #[repr(C)] anymore since the C API does
not need to access the fields in the struct.
2019-06-18 23:20:01 +02:00
Floris Bruynooghe
a6102d1039
Refactor the internal sql interface somewhat
...
Experiment with refactoring the internal sql interface a bit. My
original goal was to modify the schema and thus refactor to a state
where it would be sane to write tests for dc_sqlite_open() (and/or
however it ends up refactored) to assert schame changes before/after.
2019-06-17 22:31:36 +02:00
Floris Bruynooghe
855c7844b5
Rename to_str() -> as_str() to match stdlib naming convention
...
The function does a cast and does not create a new objects. The
stdlib convention is to use to_*() for functions which return new
objects and as_*() for functions which keep referring to the same data
but using a different type. Follow that convention.
2019-06-07 22:19:39 +02:00
dignifiedquire
95d4df6027
refactor: reduce dependencies on libc
2019-06-05 00:56:59 +02:00
dignifiedquire
8154781a0d
refactor: replace assert_rtn with assert macros
2019-05-30 00:34:10 +02:00
dignifiedquire
62e54c7291
refactor: drop libc based directory reading
2019-05-29 20:21:59 +02:00
dignifiedquire
b296ccf5a5
refactor(sqlite): replace sscanf with parse
2019-05-29 00:06:52 +02:00
Friedel Ziegelmayer
0d51c7dd2e
Prepare for android builds ( #88 )
...
* upgrade ci
* fixup
* update ci script
* Update run.sh
* refactor(time): drop libc time functions
* fix(ffi): use i64 instead off time_t
* fix(ci): install croos
* fix: remove unused dc_check_password
* fix(ffi): enable ssl vendoring by default
* chore: remove unused import
* fix(deps): add vendored flag for reqwest
* chore(ci): use cross fork
* fix: handle invalid server configurations
Closes #90
* Disable android from circle ci for now
2019-05-28 17:41:50 +02:00
Friedel Ziegelmayer
2a5d0c64d5
Cleanup imports ( #86 )
...
Cleanup imports
2019-05-27 12:58:45 +02:00
Friedel Ziegelmayer
e383752b67
Filbytes fix ( #85 )
...
* test(sqlite): add some tests for houskeeping methods
* fix(tools): handle faile metadata call
2019-05-27 11:59:25 +02:00
dignifiedquire
22868abe0e
refactor: rename dc_context to context
2019-05-27 09:32:50 +02:00
dignifiedquire
66d8421a90
refactor: remove dc_hash in favor of HashMap and HashSet
...
Closes #49
2019-05-26 23:01:17 +02:00
Friedel Ziegelmayer
94aa314f30
refactor(peerstate): safe implementation of peerstate
2019-05-26 22:33:39 +02:00
dignifiedquire
e9a42a3c56
fix(sqlite): handle non availble stats
2019-05-19 19:40:11 +02:00
Friedel Ziegelmayer
342e416b4e
Ci updates & closer to windows builds
...
* chore: update some ci
* feat: no more libiconv
* refactor: updates for updated mmime api
* fixup: correct mmime path
* cleanup
* use newer visual studio
* Update appveyor.yml
* unify libc imports and improve windows situation
* refactor: use rust based sleep
* improve cross platform state of types
* docs: update readme badges
2019-05-16 17:16:07 +02:00
dignifiedquire
dfb989e0d0
finish it
2019-05-14 00:44:59 +02:00
Lars-Magnus Skog
0bbda91e77
Fix warnings on variables not needing mut ( #48 )
...
chore: fix compiler warnings (unused mut)
2019-05-08 00:44:40 +02:00
dignifiedquire
83917ef93e
wip - use mmime instead of libetpan
2019-05-07 10:45:46 +01:00
dignifiedquire
29a9a408ef
remove unused types
2019-05-06 10:59:24 +02:00
Lars-Magnus Skog
2cf6cde5d1
chore: fix compiler warnings (mut + unused assignments) ( #40 )
...
* Stop allowing unused assignments
* test: remove unused assignments in cmdline
* chore: fix compiler warnings in dc_tools.rs
* chore: fix compiler warnings in dc_token.rs
* chore: fix compiler warnings in dc_strencode.rs
* chore: fix compiler warnings in dc_stock.rs
* chore: fix compiler warnings in dc_sqlite3.rs
* chore: fix compiler warnings in dc_simplify.rs
* chore: fix compiler warnings in dc_securejoin.rs
* chore: fix compiler warnings in dc_saxparser.rs
* chore: fix compiler warnings in dc_pgp.rs
* chore: fix compiler warnings in dc_param.rs
* chore: fix compiler warnings in dc_oauth2.rs
* chore: fix compiler warnings in dc_msg.rs
* chore: fix compiler warnings in dc_mimeparser.rs
* chore: fix compiler warnings in dc_mimefactory.rs
* chore: fix compiler warnings in dc_lot.rs
* chore: fix compiler warnings in dc_loginparams.rs
* chore: fix compiler warnings in dc_log.rs
* chore: fix compiler warnings in dc_location.rs
* chore: fix compiler warnings in dc_keyring.rs
* chore: fix compiler warnings in dc_key.rs
* chore: fix compiler warnings in dc_jsmn.rs
* chore: fix compiler warnings in dc_jobthread.rs
* chore: fix compiler warnings in dc_imex.rs
* chore: fix compiler warnings in dc_hash.rs
* chore: fix compiler warnings in dc_e2ee.rs
* chore: fix compiler warnings in dc_context.rs
* chore: fix compiler warnings in dc_contact.rs
* chore: fix compiler warnings in dc_chatlist.rs
* chore: fix compiler warnings in dc_chat.rs
* chore: fix compiler warnings in dc_array.rs
* chore: fix compiler warnings in dc_apeerstate.rs
* chore: fix compiler warnings in dc_aheader.rs
* chore: fix compiler warnings in dc_array.rs
* test: remove compiler warnings in test/stress.rs
* test: reduce compiler warnings in examples/repl/main.rs
* test: std:🧵 :sleep_ms() is deprecated
* chore: remove unused variable in dc_sqlite3.rs
* chore: fix compiler warnings in dc_receive_imf.rs
* chore: fix compiler warnings in dc_job.rs
* chore: fix compiler warnings in dc_configure.rs
* Fix formatting
2019-05-05 21:58:59 +02:00
dignifiedquire
e7d72dfdd4
fix some locking issues, start rust-imap impl
2019-05-05 00:15:45 +02:00
dignifiedquire
e187f0f250
fix: allow concurrent access to dc_sqlite3_t
2019-05-02 23:36:09 +02:00
dignifiedquire
313f71a004
it compiles
2019-05-01 23:41:11 +02:00
dignifiedquire
75319dbf67
continue rustification
2019-05-01 23:41:11 +02:00
dignifiedquire
3e971d81d4
refactor: start using rust for allocations & locks
2019-05-01 23:41:11 +02:00
dignifiedquire
aa32c53a43
fix: compiles on android 32bit
2019-04-28 17:54:23 +03:00
dignifiedquire
e8a79f220e
refactor: use architecture dependent sizes
2019-04-28 15:18:30 +03:00
dignifiedquire
e737a32c54
cleanup: remove unused imports
2019-04-27 18:02:12 +03:00
dignifiedquire
95637ba275
cleanup: fix warnings
2019-04-27 17:48:12 +03:00
dignifiedquire
4cf5903d60
feat: update latest deltachat-core 0.43.0
2019-04-27 17:35:49 +03:00
dignifiedquire
1faf248e09
remove extern c and no_mangle
2019-04-27 01:42:58 +03:00
dignifiedquire
c008d9e1a7
feat: use libsqlite3-sys
2019-04-26 22:12:23 +03:00
dignifiedquire
760e37fb39
reduce code duplication (round 1)
2019-04-26 18:45:30 +03:00
dignifiedquire
0e3b761147
reduce code duplication
2019-04-26 14:43:01 +03:00
dignifiedquire
ff99e19972
inital commit
2019-04-26 11:57:23 +03:00