diff options
author | Marius Bakke <mbakke@fastmail.com> | 2019-05-25 00:25:15 +0200 |
---|---|---|
committer | Marius Bakke <mbakke@fastmail.com> | 2019-05-25 00:25:15 +0200 |
commit | 57df83e07d4b5e78d9a54c1a88d05b4a9ed65714 (patch) | |
tree | 76684e63965e9ad6e37d9d45bc3159e6c9782cd0 /gnu/packages/patches/ocaml-piqilib-Update-base64.patch | |
parent | 43d9ed7792808638eabb43aa6133f1d6186c520b (diff) | |
parent | 136b7d81f0eb713783e9ea7cf7f260a2b6252dfd (diff) | |
download | guix-57df83e07d4b5e78d9a54c1a88d05b4a9ed65714.tar.gz |
Merge branch 'staging' into core-updates
Diffstat (limited to 'gnu/packages/patches/ocaml-piqilib-Update-base64.patch')
-rw-r--r-- | gnu/packages/patches/ocaml-piqilib-Update-base64.patch | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/gnu/packages/patches/ocaml-piqilib-Update-base64.patch b/gnu/packages/patches/ocaml-piqilib-Update-base64.patch new file mode 100644 index 0000000000..ec2c02d93e --- /dev/null +++ b/gnu/packages/patches/ocaml-piqilib-Update-base64.patch @@ -0,0 +1,46 @@ +From 98abdbff3d5316a75f27d6a76fe09317d56f2a38 Mon Sep 17 00:00:00 2001 +From: Vincent Bernardoff <vb@luminar.eu.org> +Date: Sun, 10 Feb 2019 14:47:07 +0100 +Subject: [PATCH] Fix compilation with newer base64 versions + +--- + opam | 2 +- + piqilib/piqi_base64.ml | 9 ++++----- + 2 files changed, 5 insertions(+), 6 deletions(-) + +diff --git a/opam b/opam +index 3a9128e..bb5a53f 100644 +--- a/opam ++++ b/opam +@@ -26,6 +26,6 @@ depends: [ + "easy-format" + "ulex" + "xmlm" +- "base64" {>="2.0.0"} ++ "base64" {>="3.1.0"} + ] + dev-repo: "git://github.com/alavrik/piqi" +diff --git a/piqilib/piqi_base64.ml b/piqilib/piqi_base64.ml +index c5a6ae7..a98346e 100644 +--- a/piqilib/piqi_base64.ml ++++ b/piqilib/piqi_base64.ml +@@ -18,12 +18,11 @@ + (* TODO: add more base64 validation; the base64 library doesn't do any + * validation *) + let decode x = +- try +- B64.decode x +- with _ -> +- invalid_arg "Piqi_base64.decode" ++ match Base64.decode x with ++ | Error _ -> invalid_arg "Piqi_base64.decode" ++ | Ok v -> v + + + let encode x = +- B64.encode x ++ Base64.encode_exn x + +-- +2.21.0 + |