#985860 regexp.c: change format from "%d" to "%ld" for the output of a difference of two pointers of type character

Package:
src:nn
Source:
nn
Submitter:
Bjarni Ingi Gislason
Date:
2021-03-25 01:36:04 UTC
Severity:
normal
Tags:
#985860#5
Date:
2021-03-25 01:33:08 UTC
From:
To:
Dear Maintainer,

Signed-off-by: Bjarni Ingi Gislason <bjarniig@rhi.hi.is>
---
 regexp.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/regexp.c b/regexp.c
index 316743e..9db173f 100644
--- a/regexp.c
+++ b/regexp.c
@@ -1086,12 +1086,12 @@ regdump(regexp * r)
     s = r->program + 1;
     while (op != END) {		/* While that wasn't END last time... */
 	op = OP(s);
-	printf("%2d%s", s - r->program, regprop(s));	/* Where, what. */
+	printf("%2ld%s", s - r->program, regprop(s));	/* Where, what. */
 	next = regnext(s);
 	if (next == NULL)	/* Next ptr. */
 	    printf("(0)");
 	else
-	    printf("(%d)", (s - r->program) + (next - s));
+	    printf("(%ld)", (s - r->program) + (next - s));
 	s += 3;
 	if (op == ANYOF || op == ANYBUT || op == EXACTLY) {
 	    /* Literal string, where present. */