summaryrefslogtreecommitdiff
path: root/mail/p5-MIME-Fast/files/patch-Fast_Part.xs
diff options
context:
space:
mode:
authorMathieu Arnold <mat@FreeBSD.org>2015-04-24 16:52:29 +0000
committerMathieu Arnold <mat@FreeBSD.org>2015-04-24 16:52:29 +0000
commitf0da482d08556d39b5c31a536dad637d838eae82 (patch)
tree57ef524a5f52fa7b6deca9f865afab02d5093c68 /mail/p5-MIME-Fast/files/patch-Fast_Part.xs
parentThere are actualy two chinese wordpress ports, which have both different (diff)
Fix build with 5.18+. Rename a patch to follow makepatch naming.
Sponsored by: Absolight
Diffstat (limited to 'mail/p5-MIME-Fast/files/patch-Fast_Part.xs')
-rw-r--r--mail/p5-MIME-Fast/files/patch-Fast_Part.xs30
1 files changed, 30 insertions, 0 deletions
diff --git a/mail/p5-MIME-Fast/files/patch-Fast_Part.xs b/mail/p5-MIME-Fast/files/patch-Fast_Part.xs
new file mode 100644
index 000000000000..fdb5d88f7d58
--- /dev/null
+++ b/mail/p5-MIME-Fast/files/patch-Fast_Part.xs
@@ -0,0 +1,30 @@
+--- Fast/Part.xs.orig 2004-12-20 17:59:39.603786200 +0300
++++ Fast/Part.xs 2004-12-27 18:05:31.374875000 +0300
+@@ -48,7 +48,6 @@
+ XSINTERFACE_FUNC_MIMEFAST_PART_SET
+ INTERFACE:
+ set_content_description
+- set_content_md5
+ set_content_location
+ set_content_disposition
+ set_filename
+@@ -240,6 +239,9 @@
+ g_mime_part_set_content_object(mime_part, mime_data_wrapper);
+
+ g_mime_stream_unref(mime_stream);
++ } else if (SvPOKp(svval)) {
++ data = (char *)SvPV(svval, len);
++ g_mime_part_set_content(mime_part, data, len);
+ } else if (svvaltype == SVt_PVMG) { // possible STDIN/STDOUT etc.
+ int fd0 = (int)SvIV( svval );
+ int fd;
+@@ -256,9 +258,6 @@
+ g_mime_part_set_content_object(mime_part, mime_data_wrapper);
+
+ g_mime_stream_unref(mime_stream);
+- } else if (SvPOK(svval)) {
+- data = (char *)SvPV(svval, len);
+- g_mime_part_set_content(mime_part, data, len);
+ } else {
+ croak("mime_set_content: Unknown type: %d", (int)svvaltype);
+ }