From 7cd2f0a979bb4431bf2a5b55c1ba995118cfa262 Mon Sep 17 00:00:00 2001 From: armink Date: Sun, 12 Apr 2020 22:52:43 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E5=AE=8C=E5=96=84=E3=80=91env=20?= =?UTF-8?q?=E8=8E=B7=E5=8F=96=E5=8A=9F=E8=83=BD=EF=BC=8C=E6=9F=A5=E6=89=BE?= =?UTF-8?q?=E5=A4=B1=E8=B4=A5=E5=90=8E=EF=BC=8Csave=5Flen=20=E5=B0=86?= =?UTF-8?q?=E8=A2=AB=E7=BD=AE=200=20=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: armink --- easyflash/src/ef_env.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/easyflash/src/ef_env.c b/easyflash/src/ef_env.c index 5a445ce..01bac5a 100644 --- a/easyflash/src/ef_env.c +++ b/easyflash/src/ef_env.c @@ -787,6 +787,8 @@ static size_t get_env(const char *key, void *value_buf, size_t buf_len, size_t * if (value_buf){ ef_port_read(env.addr.value, (uint32_t *) value_buf, read_len); } + } else if (value_len) { + *value_len = 0; } return read_len;