new file mode 100644
@@ -0,0 +1,19 @@
+clarify type conversion
+
+fixes
+| ruli_rand.c:54:47: error: implicit conversion from 'unsigned int' to 'float' changes value from 4294967295 to 4294967296 [-Werror,-Wimplicit-int-float-conversion]
+|
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+--- a/src/ruli_rand.c
++++ b/src/ruli_rand.c
+@@ -51,7 +51,7 @@ int ruli_rand_next(ruli_rand_t *rand_ctx
+
+ u = isaac_rand(&rand_ctx->isaac_ctx);
+
+- r = (int) ((float) (1.0 + max - min) * u / ISAAC_UB4MAXVAL + min);
++ r = (int) ((float) (1.0 + max - min) * u / (float) (ISAAC_UB4MAXVAL + min));
+
+ assert(min <= r);
+ assert(r <= max);
@@ -12,6 +12,7 @@ SRC_URI = "http://download.savannah.gnu.org/releases/ruli/ruli_${PV}.orig.tar.gz
file://0001-src-ruli_addr.c-Add-missing-format-string.patch \
file://0001-ruli_srv-Mark-prev_addr_list_size-as-unused.patch \
file://0001-Make-space-for-flags-from-environment.patch \
+ file://float-conversion.patch \
"
SRC_URI[md5sum] = "e73fbfdeadddb68a703a70cea5271468"
Signed-off-by: Khem Raj <raj.khem@gmail.com> --- .../ruli/files/float-conversion.patch | 19 +++++++++++++++++++ .../recipes-support/ruli/ruli_0.36.bb | 1 + 2 files changed, 20 insertions(+) create mode 100644 meta-networking/recipes-support/ruli/files/float-conversion.patch -- 2.24.1 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel