Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
PATCH: pws-19: mapfile bit that just sort of disappeared
- X-seq: zsh-workers 6346
- From: Peter Stephenson <pws@xxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxx (Zsh hackers list)
- Subject: PATCH: pws-19: mapfile bit that just sort of disappeared
- Date: Tue, 25 May 1999 13:49:27 +0200
- In-reply-to: "Peter Stephenson"'s message of "Tue, 25 May 1999 12:01:10 DFT." <9905251001.AA28774@xxxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
Peter Stephenson wrote:
> By the way, it looks like mapfile using mmap() doesn't write the file
> properly on HPUX, probably the file doesn't get extended properly first.
> I'll have to look at that.
No real wonder. This was there at some stage, though.
--- Src/Modules/mapfile.c.ms Sat May 22 17:05:15 1999
+++ Src/Modules/mapfile.c Tue May 25 13:40:47 1999
@@ -143,6 +143,7 @@
*/
ftruncate(fd, len);
memcpy(mmptr, value, len);
+ msync(mmptr, len, MS_SYNC);
/*
* Then we need to truncate again, since mmap() always maps complete
* pages. Honestly, I tried it without, and you need both.
--
Peter Stephenson <pws@xxxxxxxxxxxxxxxxx> Tel: +39 050 844536
WWW: http://www.ifh.de/~pws/
Dipartimento di Fisica, Via Buonarroti 2, 56127 Pisa, Italy
Messages sorted by:
Reverse Date,
Date,
Thread,
Author