Commit Graph

1906 Commits

Author SHA1 Message Date
holger krekel 18b70bff0e remove redundant unsafe dc_str_to_color impl by calling safe one, fixes #375 2019-08-15 15:48:11 +02:00
jikstra d4bd9187d6 Fix panic in dc_set_chat_profile_image because of missing
ok_to_continue=false
2019-08-15 13:36:43 +02:00
dignifiedquire 712f5a9782 refactor(tools): cleanup and make clippy a little happier
Uses a crate now for extracing image meta data, instead of our own hand rolled code.
2019-08-15 11:26:32 +02:00
Alexander Krotov 29d4f6888d Store IDs in dc_array as u32
This changes dc_array_get_raw API
2019-08-15 01:54:51 +02:00
Alexander Krotov 5b47409fb0 Remove unused dc_array_* API 2019-08-15 01:54:51 +02:00
Asiel Díaz Benítez 8077fdeddb Update examples.rst
just replaced `send_text_message` with `send_text`
2019-08-15 01:47:03 +02:00
dignifiedquire 6f290e249f chore: release v1.0.0-alpha.4 1.0.0-alpha.4 2019-08-14 13:58:51 +02:00
Simon Laux a655f2cbba fix: properly handle chat name when contact has no name
* fix chat name empty when contact has no name
Show contacts display_name instead as defined in:
https://c.delta.chat/classdc__chat__t.html#a0fb1b4850bcd899eaa06d23648a1efaf
"For one-to-one chats, this is the name of the contact"
2019-08-14 13:55:56 +02:00
dignifiedquire 0cb42f840d fix(imap): call create, not subscribe
Closes #324
2019-08-14 11:49:39 +02:00
dignifiedquire 99aabef7f3 feat: load package version during build
This removes the duplication of the version string between the `Cargo.toml` and `constants.rs`
2019-08-14 10:35:32 +02:00
holger krekel 7d51c6e4f4 fix documentation 2019-08-14 10:18:06 +02:00
Dmitry Bogatov f463fb3759 Change type of Context.dbfile to std::path::PathBuf
This change makes code more type-correct, but introduces copying: compiler
refuses to return reference to object behind Arc<RwLock>.
2019-08-14 09:43:26 +02:00
Dmitry Bogatov cb0eb0e68e refactor: make encrypted_and_signed() return bool, not libc::int 2019-08-14 09:26:08 +02:00
holger krekel 8009f220fc hold smtp lock during the full send action 2019-08-14 01:50:15 +02:00
dignifiedquire 4f1551b91f chore(ci): enable livetests 2019-08-14 01:50:15 +02:00
dignifiedquire 6ba37a135e fix(imap): reduce lock contention around session and config locks
Hopefully closes #331
2019-08-14 01:50:15 +02:00
dignifiedquire dab514d8bc feat: switch to simpler email address parsing
This stops the psl insanity and matches more closely what the c-core did

Closes #325
2019-08-14 01:48:41 +02:00
Dmitry Bogatov 8342b29618 Fix some clippy warnings 2019-08-14 01:45:39 +02:00
B. Petersen e05944c6cb simplify progress! macro 2019-08-14 01:33:57 +02:00
Alexander Krotov 88a81f5737 Return Vec from get_all_blocked
And never return nullptr from dc_get_blocked_contacts.
2019-08-13 23:56:17 +02:00
B. Petersen 9cf6ca045c send CONFIGURE_PROGRESS(0) on failure and only on failure 2019-08-13 23:55:56 +02:00
holger krekel ba381d0d0b fix failing array asserts #355 2019-08-13 23:07:38 +02:00
Friedel Ziegelmayer 033ebc7ce3 Setup clippy (#349)
Setup clippy
2019-08-13 22:37:16 +02:00
holger krekel 6292219551 fix bug that lead to all liveconfig tests failing 2019-08-13 22:34:27 +02:00
Friedel Ziegelmayer ed237c8d25 refactor(receive_imf): first pass at some more sanity 2019-08-13 17:58:32 +02:00
Alexander Krotov d46a5345d2 Use Vec instead of dc_array_t in search_chat_ids_by_contact_ids 2019-08-13 17:54:28 +02:00
dignifiedquire 523141597e chore: remove no longer needed features 2019-08-13 12:20:53 +02:00
dignifiedquire cfed5c914c chore: update rust nightly version 2019-08-13 12:20:53 +02:00
dignifiedquire 20f9bb3b14 chore: setup clippy 2019-08-13 12:20:53 +02:00
Friedel Ziegelmayer 6067160582 Implement procedural macro to derive {To,From}Sql traits (#322)
Implement procedural macro to derive {To,From}Sql traits
2019-08-13 12:16:24 +02:00
Alexander Krotov 3175c4f7ba Merge pull request #333 from link2xt/dc_array-assert
dc_array: panic on null pointers and out of range indexes
2019-08-13 12:53:46 +03:00
Simon Laux a29f06a730 cargo fmt 2019-08-13 10:45:27 +02:00
Simon Laux c713474d1f remove lot magic 2019-08-13 10:45:27 +02:00
Simon Laux 89c874d4a9 remove message magic
there is still a reference to C #[repr(C)] so I'm not sure at this
2019-08-13 10:45:27 +02:00
Simon Laux 5e3cba9b70 remove chat magic 2019-08-13 10:45:27 +02:00
Dmitry Bogatov a7894fd785 cargo fmt 2019-08-13 10:11:17 +02:00
Dmitry Bogatov c638a770f9 Remove redundant check
Condition '!imffields.is_null()' is always true, since it is contained in conditional

	  if !(in_out_message.is_null() || imffields.is_null()) {

which is equivalent to

	  if !in_out_message.is_null() && !imffields.is_null() {
2019-08-13 10:11:17 +02:00
Simon Laux 6ced6ac23b macro for progress event like in C core 2019-08-13 10:07:13 +02:00
Simon Laux d0b77b61eb cargo fmt 2019-08-13 10:07:13 +02:00
Simon Laux b440c3636b replace gotos with ok_to_continue 2019-08-13 10:07:13 +02:00
Floris Bruynooghe dfd58961f7 Safe load_or_generate_self_public_key
The function is made safe and now returns Result.  Functionally it now
fails when it can not write the newly generated key to the database
whereas before it still returned the key but logged a warning.  There
is no reason this shouldn't be able to store the key and silently not
storing the key may result in later operations assuming the key is
available, so failing seems like a better choice.

The function now also uses a proper mutex to guard against multiple
threads generating keys.  And this mutex is Context-scoped rather than
fully global (static).
2019-08-13 10:04:38 +02:00
Jikstra 139c9f37b1 Merge pull request #339 from deltachat/rm_goto_dc_job
rm GOTO: dc job
2019-08-13 02:10:08 +02:00
Jikstra 2445b12898 Merge pull request #342 from deltachat/rm_goto_cmdline
rm GOTO: cmdline
2019-08-13 02:09:14 +02:00
Alexander Krotov 4d402f3a06 dc_array: panic on null pointers and out of range indexes 2019-08-13 03:07:13 +03:00
Jikstra ab022ccc33 Merge pull request #334 from link2xt/dc_get_chat_contacts_vec
Return Vec from dc_get_chat_contacts
2019-08-13 02:03:58 +02:00
Alexander Krotov fb7bbac524 Return Vec from dc_get_chat_contacts 2019-08-13 02:37:18 +03:00
Jikstra 39fbff5fb6 Merge pull request #347 from link2xt/dc_array_t-new
Implement From<Vec<u32>> for dc_array_t and use it instead of new()
2019-08-13 01:30:10 +02:00
Jikstra 3ac1eaf7d2 Merge pull request #341 from deltachat/add_cmdline_quit_cmd
add quit command as alias to exit in cmdline
2019-08-13 00:49:27 +02:00
Alexander Krotov 6c95d008e0 Implement From<Vec<u32>> for dc_array_t and use it instead of new() 2019-08-13 01:40:47 +03:00
Friedel Ziegelmayer 16f891c290 Merge pull request #337 from deltachat/fix-cmdline
fix 'chats' command in cmdline tool
2019-08-12 10:39:11 +02:00