summaryrefslogtreecommitdiff
path: root/src/memline.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/memline.c')
-rw-r--r--src/memline.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/memline.c b/src/memline.c
index 5d43dc3f0..80a870a0e 100644
--- a/src/memline.c
+++ b/src/memline.c
@@ -55,10 +55,14 @@
# include <time.h>
#endif
-#ifdef SASC
+#if defined(SASC) || defined(__amigaos4__)
# include <proto/dos.h> /* for Open() and Close() */
#endif
+#ifdef HAVE_ERRNO_H
+# include <errno.h>
+#endif
+
typedef struct block0 ZERO_BL; /* contents of the first block */
typedef struct pointer_block PTR_BL; /* contents of a pointer block */
typedef struct data_block DATA_BL; /* contents of a data block */
@@ -4481,7 +4485,7 @@ ml_updatechunk(buf, line, len, updtype)
curchnk = buf->b_ml.ml_chunksize + curix;
if (updtype == ML_CHNK_DELLINE)
- len *= -1;
+ len = -len;
curchnk->mlcs_totalsize += len;
if (updtype == ML_CHNK_ADDLINE)
{