diff options
author | johans <johans@FreeBSD.org> | 2009-03-10 06:26:09 +0800 |
---|---|---|
committer | johans <johans@FreeBSD.org> | 2009-03-10 06:26:09 +0800 |
commit | 2ede5e1e4c9acbe317c9ac7a6cc604092cb34f0f (patch) | |
tree | 46c4e15c12d712ff8eeda3fda60bb3f390b86f14 /lang/cduce | |
parent | 2afaf7d28416d9b96000156fc8409e51781ab61a (diff) | |
download | freebsd-ports-gnome-2ede5e1e4c9acbe317c9ac7a6cc604092cb34f0f.tar.gz freebsd-ports-gnome-2ede5e1e4c9acbe317c9ac7a6cc604092cb34f0f.tar.zst freebsd-ports-gnome-2ede5e1e4c9acbe317c9ac7a6cc604092cb34f0f.zip |
Fix build with new ocaml-ocurl (if curl is enabled)
Diffstat (limited to 'lang/cduce')
-rw-r--r-- | lang/cduce/files/patch-parser_cduce_curl.ml | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/lang/cduce/files/patch-parser_cduce_curl.ml b/lang/cduce/files/patch-parser_cduce_curl.ml new file mode 100644 index 000000000000..f9d04b01077b --- /dev/null +++ b/lang/cduce/files/patch-parser_cduce_curl.ml @@ -0,0 +1,18 @@ +--- parser/cduce_curl.ml 2008-02-25 11:10:42.000000000 +0100 ++++ parser/cduce_curl.ml 2009-02-13 16:52:26.000000000 +0100 +@@ -9,7 +9,14 @@ + let buff = Buffer.create 4096 in + let conn = Curl.init () in + Curl.set_url conn s; +- Curl.set_writefunction conn (Buffer.add_string buff); ++ Curl.set_writefunction conn ( ++ fun str -> ++ try ++ Buffer.add_string buff str; ++ String.length str ++ with ++ Failure _ -> 0 ++ ); + Curl.perform conn; + Buffer.contents buff + with Curl.CurlException (code, n, msg) -> |