aboutsummaryrefslogtreecommitdiffstats
path: root/tests/gpgscm/scheme-private.h
diff options
context:
space:
mode:
authorNIIBE Yutaka <[email protected]>2016-09-15 00:17:59 +0000
committerNIIBE Yutaka <[email protected]>2016-09-15 00:17:59 +0000
commit68eb5fbd37c31ed7c0c916656131eea7bb58d13d (patch)
treeeb384f6d83e3817e2f634c60c98d78305d0d0278 /tests/gpgscm/scheme-private.h
parentg10: Fix whitespace. (diff)
downloadgnupg-68eb5fbd37c31ed7c0c916656131eea7bb58d13d.tar.gz
gnupg-68eb5fbd37c31ed7c0c916656131eea7bb58d13d.zip
tests/gpgscm: Fix use of pointer.
* tests/gpgscm/scheme-private.h (struct scheme): Use (void *) for alloc_seg. * tests/gpgscm/scheme.c (alloc_cellseg): Use (void *) for cp. Use (void *) for coercion of address calculation. -- In old C language, (char *) means an address. In modern C, it's specifically an address with alignment=1. It's good to use (void *) for an address, because newer compiler emits warnings. Note: in this particular case, it is just a warning and the code is safe against invalid alignment, though. Signed-off-by: NIIBE Yutaka <[email protected]>
Diffstat (limited to '')
-rw-r--r--tests/gpgscm/scheme-private.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/gpgscm/scheme-private.h b/tests/gpgscm/scheme-private.h
index 9eafe766d..727e0c0bb 100644
--- a/tests/gpgscm/scheme-private.h
+++ b/tests/gpgscm/scheme-private.h
@@ -78,7 +78,7 @@ int tracing;
#ifndef CELL_NSEGMENT
#define CELL_NSEGMENT 10 /* # of segments for cells */
#endif
-char *alloc_seg[CELL_NSEGMENT];
+void *alloc_seg[CELL_NSEGMENT];
pointer cell_seg[CELL_NSEGMENT];
int last_cell_seg;