trusted-keys.exp: add \r delimiter when parsing number
In order to match all the digits in a number on its own line, use
(\\d+)\r not (\\d+) which could return a truncated value depending
on what the content of input buffer is when the matching is done.
Signed-off-by: Jerome Forissier <jerome@forissier.org>
Reviewed-by: Sumit Garg <sumit.garg@linaro.org>
diff --git a/trusted-keys.exp b/trusted-keys.exp
index c6e3327..a7200f5 100644
--- a/trusted-keys.exp
+++ b/trusted-keys.exp
@@ -9,7 +9,7 @@
set ek_id 0
proc check_keyctl_result arg {
expect {
- -re "(\n)(\\d+)" {
+ -re "(\n)(\\d+)\r" {
set ::$arg $expect_out(2,string)
exp_continue
}