diff options
author | danfe <danfe@FreeBSD.org> | 2018-01-08 22:46:00 +0800 |
---|---|---|
committer | danfe <danfe@FreeBSD.org> | 2018-01-08 22:46:00 +0800 |
commit | dbe45c27070cb8fe73bf97676aa18d1e955f2d91 (patch) | |
tree | a938440cc79f87826dc947385a766bbce0b565e8 /editors | |
parent | 67eba3451e82ce45509cc6afe92a3d403abb6f26 (diff) | |
download | freebsd-ports-gnome-dbe45c27070cb8fe73bf97676aa18d1e955f2d91.tar.gz freebsd-ports-gnome-dbe45c27070cb8fe73bf97676aa18d1e955f2d91.tar.zst freebsd-ports-gnome-dbe45c27070cb8fe73bf97676aa18d1e955f2d91.zip |
Quickly fix a segmentation fault when trying to open About dialog, by
clearing `errno' prior to calling strtol(3).
Typically this is not needed (return value must be checked before the
`errno' check), but in case of strtol(3) return value can be zero for
both successful and failed conversions.
Diffstat (limited to 'editors')
-rw-r--r-- | editors/medit/Makefile | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/editors/medit/Makefile b/editors/medit/Makefile index 781b2f186d8b..1e5a8f364a49 100644 --- a/editors/medit/Makefile +++ b/editors/medit/Makefile @@ -36,5 +36,7 @@ post-patch: @${REINPLACE_CMD} -e '/std::nullptr_t/ { x ; \ s/.*/#include <cstddef>/ ; G ; }' \ ${WRKSRC}/moo/moopython/moopython-utils.h + @${REINPLACE_CMD} -e 's/long val = strtol/errno = 0; &/' \ + ${WRKSRC}/moo/mooutils/mooglade.c .include <bsd.port.mk> |