From: Klas Lindfors Date: Wed, 28 Mar 2012 11:21:03 +0000 (+0200) Subject: defaults for updates X-Git-Tag: v1.7.0~1^2~47 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=31b45f45f1f9a9124221735e1d1d3106831dead8;p=yubikey-personalization defaults for updates by default add ALLOW_UPDATE to updates. --- diff --git a/ykpers.c b/ykpers.c index e96140b..d18be63 100644 --- a/ykpers.c +++ b/ykpers.c @@ -121,6 +121,10 @@ int ykp_configure_command(YKP_CONFIG *cfg, uint8_t command, YK_STATUS *st) break; case SLOT_UPDATE1: case SLOT_UPDATE2: + { + struct config_st *core_config = (struct config_st *) ykp_core_config(cfg); + core_config->extFlags |= EXTFLAG_ALLOW_UPDATE; + } case SLOT_SWAP: if (!((cfg->yk_major_version == 2 && cfg->yk_minor_version >= 3) || cfg->yk_major_version > 2)) { @@ -131,9 +135,9 @@ int ykp_configure_command(YKP_CONFIG *cfg, uint8_t command, YK_STATUS *st) default: ykp_errno = YKP_EINVCONFNUM; return 0; - } - cfg->command = command; - return 1; + } + cfg->command = command; + return 1; } int ykp_configure_for(YKP_CONFIG *cfg, int confnum, YK_STATUS *st)