fix compile errors
parent
e7ccb46254
commit
a85be4658c
|
@ -12,11 +12,11 @@ FUNCTION: int sysctl ( int* name, uint namelen, void* oldp, size_t* oldlenp, voi
|
||||||
: make-int-array ( seq -- byte-array )
|
: make-int-array ( seq -- byte-array )
|
||||||
[ <int> ] map concat ;
|
[ <int> ] map concat ;
|
||||||
|
|
||||||
: (sysctl-query) ( name namelen oldp oldlenp -- oldp error/f )
|
: (sysctl-query) ( name namelen oldp oldlenp -- oldp )
|
||||||
over >r f 0 sysctl io-error r> ;
|
over [ f 0 sysctl io-error ] dip ;
|
||||||
|
|
||||||
: sysctl-query ( seq n -- byte-array )
|
: sysctl-query ( seq n -- byte-array )
|
||||||
>r [ make-int-array ] [ length ] bi r>
|
[ [ make-int-array ] [ length ] bi ] dip
|
||||||
[ <byte-array> ] [ <uint> ] bi (sysctl-query) ;
|
[ <byte-array> ] [ <uint> ] bi (sysctl-query) ;
|
||||||
|
|
||||||
: sysctl-query-string ( seq -- n )
|
: sysctl-query-string ( seq -- n )
|
||||||
|
|
Loading…
Reference in New Issue