merged in sync

ENGINE-641
commit e38f6717fe

@ -249,7 +249,7 @@ static PEP_STATUS validate_fpr(PEP_SESSION session,
case PEP_ct_key_revoked:
case PEP_ct_key_b0rken:
// delete key from being default key for all users/identities
status = remove_fpr_as_default(session, fpr); //BUFF: considers the key as "revoked" ...
status = remove_fpr_as_default(session, fpr);
status = update_trust_for_fpr(session,
fpr,
ct);
@ -257,7 +257,7 @@ static PEP_STATUS validate_fpr(PEP_SESSION session,
free(ident->fpr);
ident->fpr = NULL;
ident->comm_type = ct;
status = PEP_KEY_UNSUITABLE; //BUFF: ... and returns PEP_KEY_UNSUITABLE
status = PEP_KEY_UNSUITABLE;
default:
break;
}

@ -2594,8 +2594,8 @@ static bool pull_up_attached_main_msg(message* src) {
if ((!slong || slong[0] == '\0')
&& (!sform || sform[0] == '\0')) {
if (satt) {
const char* inner_mime_type = satt->mime_type;
const char* inner_mime_type = (satt ? satt->mime_type : NULL);
if (inner_mime_type) {
if (strcasecmp(inner_mime_type, "text/plain") == 0) {
free(slong); /* in case of "" */
src->longmsg = strndup(satt->value, satt->size);

@ -552,6 +552,7 @@ tstylesheet {
status = PEP_«yml:ucase(@name)»_CANNOT_ENCRYPT;
goto the_end;
}
add_opt_field(m, "pEp-auto-consume", "yes");
free_message(_m);
break;
@ -729,6 +730,7 @@ tstylesheet {
status = PEP_«yml:ucase(@name)»_CANNOT_ENCRYPT;
goto the_end;
}
add_opt_field(m, "pEp-auto-consume", "yes");
free_message(_m);
break;
@ -752,6 +754,7 @@ tstylesheet {
status = PEP_«yml:ucase(@name)»_CANNOT_ENCRYPT;
goto the_end;
}
add_opt_field(m, "pEp-auto-consume", "yes");
free_message(_m);
}
@ -1046,8 +1049,10 @@ tstylesheet {
// state machine
#ifndef NDEBUG
const char *«@name»_state_name(int state);
const char *«@name»_event_name(int event);
#endif
// the state machine function is returning the next state in case of a
// transition or None for staying
@ -1073,6 +1078,9 @@ tstylesheet {
#include "«@name»_fsm.h"
#include <stdlib.h>
#ifdef NDEBUG
static
#endif
const char *«@name»_state_name(int state)
{
switch (state) {
@ -1093,6 +1101,9 @@ tstylesheet {
}
}
#ifdef NDEBUG
static
#endif
const char *«@name»_event_name(int event)
{
switch (event) {
@ -1158,7 +1169,7 @@ tstylesheet {
switch (state) {
`` apply "state", 2, mode=fsm
default:
«@name»_ERR_LOG_INT("invalid state", state);
«@name»_ERR_LOG("invalid state", «@name»_state_name(state));
return invalid_state;
}

@ -10,7 +10,7 @@ include ./fsm.yml2
protocol Sync 1 {
// all messages have a timestamp, time out and are removed after timeout
fsm KeySync 1, threshold=60 {
fsm KeySync 1, threshold=300 {
version 1, 2;
state InitState {

Loading…
Cancel
Save