mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-26 12:53:13 +00:00
Remove obsolete workaround for strftime on BSD
This was added in libc 0.2.152, see aff5e66e54
This commit is contained in:
parent
798150ac39
commit
48a6550688
1 changed files with 0 additions and 11 deletions
|
@ -1413,17 +1413,6 @@ fn format_history_record(
|
|||
if !unsafe { libc::localtime_r(&seconds, &mut timestamp).is_null() } {
|
||||
const max_tstamp_length: usize = 100;
|
||||
let mut timestamp_str = [0_u8; max_tstamp_length];
|
||||
// The libc crate fails to declare strftime on BSD.
|
||||
#[cfg(bsd)]
|
||||
extern "C" {
|
||||
fn strftime(
|
||||
buf: *mut libc::c_char,
|
||||
maxsize: usize,
|
||||
format: *const libc::c_char,
|
||||
timeptr: *const libc::tm,
|
||||
) -> usize;
|
||||
}
|
||||
#[cfg(not(bsd))]
|
||||
use libc::strftime;
|
||||
if unsafe {
|
||||
strftime(
|
||||
|
|
Loading…
Reference in a new issue