The compiler says:
dotinit.c: In function 'doDot':
dotinit.c:454:24: warning: conversion to 'unsigned int' from 'int' may change
the sign of the result [-Wsign-conversion]
454 | pinfo.margin = Pack;
| ^~~~
But from the surrounding code and the implementation of `getPack`, we can
statically determine that `Pack` is non-negative at this point.
* Contributors: Details at https://graphviz.org
*************************************************************************/
-
+#include <assert.h>
#include <time.h>
#include <dotgen/dot.h>
#include <pack/pack.h>
pinfo.mode = l_graph;
else if (Pack < 0)
Pack = CL_OFFSET;
- pinfo.margin = Pack;
+ assert(Pack >= 0);
+ pinfo.margin = (unsigned)Pack;
pinfo.fixed = NULL;
/* components using clusters */