diff --git a/sys/man/2/segbrk b/sys/man/2/segbrk index 9cdb18f0b..f20838e36 100644 --- a/sys/man/2/segbrk +++ b/sys/man/2/segbrk @@ -24,8 +24,8 @@ A call to .I segbrk with a zero .I addr -argument returns the address -of the top of bss. +argument returns the base address of the segment without +altering its size. .PP The system will prevent segments from overlapping and will not allow the length of the @@ -46,13 +46,6 @@ returns .B (void*)-1 on error. .SH BUGS -.I Segbrk -is not fully defined or implemented. -In particular, -it cannot always return the top of bss -when called with a zero -.I addr -argument. The .I segbrk system call may go away or be re-implemented diff --git a/sys/src/9/port/segment.c b/sys/src/9/port/segment.c index a9eb26eaf..e9e8959df 100644 --- a/sys/src/9/port/segment.c +++ b/sys/src/9/port/segment.c @@ -376,7 +376,7 @@ putimage(Image *i) ccloseq(c); /* does not block */ } -long +uintptr ibrk(uintptr addr, int seg) { Segment *s, *ns;