pkgsrc/mail/ja-mh/patches/patch-ar
taca f7ee73e0ba * Fix build problem on NetBSD current, terminfo case.
* Add comments to each patch file.
2010-09-27 12:01:49 +00:00

27 lines
995 B
Text

$NetBSD: patch-ar,v 1.4 2010/09/27 12:01:49 taca Exp $
* Add Dragonfly support.
--- uip/scansbr.c.orig 2006-04-11 14:23:48.000000000 +0000
+++ uip/scansbr.c
@@ -253,6 +253,8 @@ register FILE *inb;
while (state == BODY) {
#ifdef _STDIO_USES_IOSTREAM
if (scnout->_IO_write_ptr == scnout->_IO_write_end) {
+#elif defined(__DragonFly__)
+ if (((struct __FILE_public *)scnout)->_r <= 0) {
#else
if (scnout->_cnt <= 0) {
#endif
@@ -264,6 +266,11 @@ register FILE *inb;
(long)scnout->_IO_write_ptr-(long)scnout->_IO_write_end,
inb);
scnout->_IO_write_ptr += msg_count;
+#elif defined(__DragonFly__)
+ state = m_getfld( state, name, ((struct __FILE_public *)scnout)->_p,
+ -(((struct __FILE_public *)scnout)->_r), inb );
+ ((struct __FILE_public *)scnout)->_r -= msg_count;
+ ((struct __FILE_public *)scnout)->_p += msg_count;
#else
state = m_getfld( state, name, scnout->_ptr,
-(scnout->_cnt), inb );