FreeBSD Bugzilla – Attachment 157483 Details for
Bug 200682
[UPDATE] editors/mg to 20150323
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch to update editors/mg
mg.diff (text/plain), 4.71 KB, created by
Olivier Duchateau
on 2015-06-06 20:46:28 UTC
(
hide
)
Description:
Patch to update editors/mg
Filename:
MIME Type:
Creator:
Olivier Duchateau
Created:
2015-06-06 20:46:28 UTC
Size:
4.71 KB
patch
obsolete
>Index: Makefile >=================================================================== >--- Makefile (revision 388682) >+++ Makefile (working copy) >@@ -2,7 +2,7 @@ > # $FreeBSD$ > > PORTNAME= mg >-PORTVERSION= 20140414 >+PORTVERSION= 20150323 > CATEGORIES= editors > MASTER_SITES= http://homepage.boetes.org/software/mg/ > >Index: distinfo >=================================================================== >--- distinfo (revision 388682) >+++ distinfo (working copy) >@@ -1,2 +1,2 @@ >-SHA256 (mg-20140414.tar.gz) = 89ce25ee13cedc14c3c5c7b76d7a9e0ea38a060ad61e90ac43258d8dadf0d065 >-SIZE (mg-20140414.tar.gz) = 142570 >+SHA256 (mg-20150323.tar.gz) = d71b24d47d3e1426f162e446d92dfa457df96dd47c1289419cba9fd14c2c3afb >+SIZE (mg-20150323.tar.gz) = 142105 >Index: files/patch-autoexec.c >=================================================================== >--- files/patch-autoexec.c (revision 0) >+++ files/patch-autoexec.c (working copy) >@@ -0,0 +1,34 @@ >+--- autoexec.c.orig 2015-03-23 11:03:05 UTC >++++ autoexec.c >+@@ -2,12 +2,17 @@ >+ /* this file is in the public domain */ >+ /* Author: Vincent Labrecque <vincent@openbsd.org> April 2002 */ >+ >++#include <sys/param.h> >+ #include <sys/queue.h> >+ #include <fnmatch.h> >+ #include <signal.h> >+ #include <stdio.h> >+ #include <stdlib.h> >+ #include <string.h> >++#ifndef __OpenBSD__ >++#include <stdlib.h> >++#include <malloc_np.h> >++#endif >+ >+ #include "def.h" >+ #include "funmap.h" >+@@ -44,8 +49,13 @@ find_autoexec(const char *fname) >+ SLIST_FOREACH(ae, &autos, next) { >+ if (fnmatch(ae->pattern, fname, 0) == 0) { >+ if (used >= have) { >++ #if defined(__OpenBSD__) >+ npfl = reallocarray(pfl, have + AUTO_GROW + 1, >+ sizeof(PF)); >++ #else >++ npfl = realloc(pfl, (have + AUTO_GROW + 1) * >++ sizeof(PF)); >++ #endif >+ if (npfl == NULL) >+ panic("out of memory"); >+ pfl = npfl; > >Property changes on: files/patch-autoexec.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-def.h >=================================================================== >--- files/patch-def.h (revision 0) >+++ files/patch-def.h (working copy) >@@ -0,0 +1,11 @@ >+--- def.h.orig 2015-03-23 11:23:30 UTC >++++ def.h >+@@ -13,6 +13,8 @@ >+ #include "chrdef.h" >+ #include "ttydef.h" >+ >++#include <sys/types.h> >++ >+ >+ /* necesarry to get asprintf & friends with glibc XXX doesn't work for some >+ * mysterious reason! */ > >Property changes on: files/patch-def.h >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-display.c >=================================================================== >--- files/patch-display.c (revision 0) >+++ files/patch-display.c (working copy) >@@ -0,0 +1,40 @@ >+--- display.c.orig 2015-03-16 14:39:00 UTC >++++ display.c >+@@ -170,14 +170,6 @@ vtresize(int force, int newrow, int newc >+ (a) = tmp; \ >+ } while (0) >+ >+-#define TRYREALLOCARRAY(a, n, m) do { \ >+- void *tmp; \ >+- if ((tmp = reallocarray((a), (n), (m))) == NULL) {\ >+- panic("out of memory in display code"); \ >+- } \ >+- (a) = tmp; \ >+- } while (0) >+- >+ /* No update needed */ >+ if (!first_run && !force && !rowchanged && !colchanged) >+ return (TRUE); >+@@ -206,10 +198,10 @@ vtresize(int force, int newrow, int newc >+ } >+ } >+ >+- TRYREALLOCARRAY(score, newrow, newrow * sizeof(struct score)); >+- TRYREALLOCARRAY(vscreen, (newrow - 1), sizeof(struct video *)); >+- TRYREALLOCARRAY(pscreen, (newrow - 1), sizeof(struct video *)); >+- TRYREALLOCARRAY(video, (newrow - 1), 2 * sizeof(struct video)); >++ TRYREALLOC(score, newrow * newrow * sizeof(struct score)); >++ TRYREALLOC(vscreen, (newrow - 1) * sizeof(struct video *)); >++ TRYREALLOC(pscreen, (newrow - 1) * sizeof(struct video *)); >++ TRYREALLOC(video, ((newrow - 1) * 2) * sizeof(struct video)); >+ >+ /* >+ * Zero-out the entries we just allocated. >+@@ -247,7 +239,6 @@ vtresize(int force, int newrow, int newc >+ } >+ >+ #undef TRYREALLOC >+-#undef TRYREALLOCARRAY >+ >+ /* >+ * Initialize the data structures used > >Property changes on: files/patch-display.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 200682
: 157483