|
|
@ -1954,8 +1954,13 @@ wiconf: |
|
|
|
return strdup("failed.DATA"); |
|
|
|
return strdup("failed.DATA"); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
// Only flag a successful share
|
|
|
|
// Only flag a successful share
|
|
|
|
|
|
|
|
int32_t errn; |
|
|
|
|
|
|
|
TXT_TO_INT("errn", transfer_data(i_errn), errn); |
|
|
|
ck_wlock(&last_lock); |
|
|
|
ck_wlock(&last_lock); |
|
|
|
|
|
|
|
if (errn == SE_NONE) |
|
|
|
setnow(&last_share); |
|
|
|
setnow(&last_share); |
|
|
|
|
|
|
|
else |
|
|
|
|
|
|
|
setnow(&last_share_inv); |
|
|
|
ck_wunlock(&last_lock); |
|
|
|
ck_wunlock(&last_lock); |
|
|
|
} |
|
|
|
} |
|
|
|
LOGDEBUG("%s.ok.added %s", id, transfer_data(i_nonce)); |
|
|
|
LOGDEBUG("%s.ok.added %s", id, transfer_data(i_nonce)); |
|
|
@ -2492,6 +2497,9 @@ static char *cmd_homepage(__maybe_unused PGconn *conn, char *cmd, char *id, |
|
|
|
ftv_to_buf(&last_share, reply, siz); |
|
|
|
ftv_to_buf(&last_share, reply, siz); |
|
|
|
snprintf(tmp, sizeof(tmp), "lastsh=%s%c", reply, FLDSEP); |
|
|
|
snprintf(tmp, sizeof(tmp), "lastsh=%s%c", reply, FLDSEP); |
|
|
|
APPEND_REALLOC(buf, off, len, tmp); |
|
|
|
APPEND_REALLOC(buf, off, len, tmp); |
|
|
|
|
|
|
|
ftv_to_buf(&last_share_inv, reply, siz); |
|
|
|
|
|
|
|
snprintf(tmp, sizeof(tmp), "lastshinv=%s%c", reply, FLDSEP); |
|
|
|
|
|
|
|
APPEND_REALLOC(buf, off, len, tmp); |
|
|
|
ftv_to_buf(&last_auth, reply, siz); |
|
|
|
ftv_to_buf(&last_auth, reply, siz); |
|
|
|
ck_wunlock(&last_lock); |
|
|
|
ck_wunlock(&last_lock); |
|
|
|
snprintf(tmp, sizeof(tmp), "lastau=%s%c", reply, FLDSEP); |
|
|
|
snprintf(tmp, sizeof(tmp), "lastau=%s%c", reply, FLDSEP); |
|
|
|