mirror of
https://github.com/chatmail/core.git
synced 2026-05-08 01:16:31 +03:00
send CONFIGURE_PROGRESS(0) on failure and only on failure
This commit is contained in:
committed by
holger krekel
parent
ba381d0d0b
commit
9cf6ca045c
@@ -17,8 +17,8 @@ macro_rules! progress {
|
|||||||
($context:tt, $progress:expr) => {
|
($context:tt, $progress:expr) => {
|
||||||
$context.call_cb(
|
$context.call_cb(
|
||||||
Event::CONFIGURE_PROGRESS,
|
Event::CONFIGURE_PROGRESS,
|
||||||
(if $progress < 1 {
|
(if $progress < 0 {
|
||||||
1
|
0
|
||||||
} else if $progress > 1000 {
|
} else if $progress > 1000 {
|
||||||
1000
|
1000
|
||||||
} else {
|
} else {
|
||||||
@@ -151,7 +151,7 @@ pub unsafe fn dc_job_do_DC_JOB_CONFIGURE_IMAP(context: &Context, _job: *mut dc_j
|
|||||||
let s = s_a.read().unwrap();
|
let s = s_a.read().unwrap();
|
||||||
|
|
||||||
if !s.shall_stop_ongoing {
|
if !s.shall_stop_ongoing {
|
||||||
progress!(context, 0);
|
progress!(context, 1);
|
||||||
|
|
||||||
let mut param = dc_loginparam_read(context, &context.sql, "");
|
let mut param = dc_loginparam_read(context, &context.sql, "");
|
||||||
if param.addr.is_empty() {
|
if param.addr.is_empty() {
|
||||||
|
|||||||
Reference in New Issue
Block a user