summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'README.md')
-rw-r--r--README.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/README.md b/README.md
index cf03cac8..344b4eef 100644
--- a/README.md
+++ b/README.md
@@ -26,8 +26,8 @@ call:
// libc api (unsafe, requires handling return code/errno)
pub unsafe extern fn gethostname(name: *mut c_char, len: size_t) -> c_int;
-// nix api (returns a nix::Result)
-pub fn gethostname(name: &mut [u8]) -> Result<()>;
+// nix api (returns a nix::Result<CStr>)
+pub fn gethostname<'a>(buffer: &'a mut [u8]) -> Result<&'a CStr>;
```
## Supported Platforms