Skip to content

Commit 9be9482

Browse files
DiuDiu777tgross35
andauthored
Update library/alloc/src/ffi/c_str.rs
Co-authored-by: Trevor Gross <[email protected]>
1 parent b560854 commit 9be9482

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/alloc/src/ffi/c_str.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,7 @@ impl CString {
352352
/// # Safety
353353
///
354354
/// This should only ever be called with a pointer that was earlier
355-
/// obtained by calling [`CString::into_raw`] and the memory it points to must not be accessed
355+
/// obtained by calling [`CString::into_raw`], and the memory it points to must not be accessed
356356
/// through any other pointer during the lifetime of reconstructed `CString`.
357357
/// Other usage (e.g., trying to take ownership of a string that was allocated by foreign code)
358358
/// is likely to lead to undefined behavior or allocator corruption.

0 commit comments

Comments
 (0)