add assertions to silence clang false positive

(cherry picked from commit bed9ad79)
40 jobs for !1844 with clang-false-positive-v9_14 in 16 minutes and 22 seconds (queued for 6 seconds)
detached
Status Job ID Name Coverage
  Precheck
passed #218514
linux amd64
🐞:sid:amd64

00:00:39

passed #218513
linux amd64
misc:sid:amd64

00:00:17

 
  Build
passed #218525
linux amd64
asan:sid:amd64

00:01:24

passed #218526
linux amd64
clang:stretch:amd64

00:01:21

passed #218527
linux i386
clang:stretch:i386

00:01:47

passed #218515
linux amd64
docs:sid:amd64

00:00:43

passed #218524
linux amd64
gcc:bionic:amd64

00:02:05

passed #218516
linux amd64
gcc:centos6:amd64

00:02:27

passed #218517
linux amd64
gcc:centos7:amd64

00:02:12

passed #218522
linux amd64
gcc:fedora29:amd64

00:02:07

passed #218518
linux amd64
gcc:jessie:amd64

00:01:19

passed #218520
linux amd64
gcc:sid:amd64

00:01:45

passed #218521
linux i386
gcc:sid:i386

00:01:46

passed #218519
linux amd64
gcc:stretch:amd64

00:01:23

passed #218523
linux amd64
gcc:xenial:amd64

00:01:07

passed #218528
linux amd64
pkcs11:sid:amd64

00:01:40

 
  Test
passed #218547
linux amd64
system:asan:sid:amd64

00:08:41

passed #218545
linux amd64
system:gcc:bionic:amd64

00:07:28

passed #218529
linux amd64
system:gcc:centos6:amd64

00:06:37

passed #218591
linux amd64
system:gcc:centos7:amd64

00:06:27

passed #218541
linux amd64
system:gcc:fedora29:amd64

00:06:53

passed #218533
linux amd64
system:gcc:jessie:amd64

00:06:51

passed #218537
linux amd64
system:gcc:sid:amd64

00:06:31

passed #218539
linux i386
system:gcc:sid:i386

00:07:04

passed #218535
linux amd64
system:gcc:stretch:amd64

00:07:05

passed #218543
linux amd64
system:gcc:xenial:amd64

00:07:17

passed #218550
linux amd64
system:pkcs11:sid:amd64

00:07:30

passed #218548
linux amd64
unit:asan:sid:amd64

00:00:59

passed #218549
linux amd64
unit:clang:stretch:amd64

00:00:42

passed #218546
linux amd64
unit:gcc:bionic:amd64

00:00:52

passed #218530
linux amd64
unit:gcc:centos6:amd64

00:00:55

passed #218532
linux amd64
unit:gcc:centos7:amd64

00:00:57

passed #218542
linux amd64
unit:gcc:fedora29:amd64

00:00:52

passed #218534
linux amd64
unit:gcc:jessie:amd64

00:00:30

passed #218538
linux amd64
unit:gcc:sid:amd64

00:00:55

passed #218540
linux i386
unit:gcc:sid:i386

00:00:53

passed #218536
linux amd64
unit:gcc:stretch:amd64

00:00:54

passed #218544
linux amd64
unit:gcc:xenial:amd64

00:00:49

passed #218551
linux amd64
unit:pkcs11:sid:amd64

00:00:50

failed #218531
linux amd64
system:gcc:centos7:amd64

00:06:39