Skip to content

Commit c805283

Browse files
committed
strftime_l for Linux glibc/musl
1 parent e06d905 commit c805283

File tree

4 files changed

+16
-0
lines changed

4 files changed

+16
-0
lines changed

libc-test/semver/linux-gnu.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -649,6 +649,7 @@ eaccess
649649
asctime_r
650650
ctime_r
651651
strftime
652+
strftime_l
652653
strptime
653654
dirname
654655
posix_basename

libc-test/semver/linux-musl.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ euidaccess
5454
eaccess
5555
asctime_r
5656
strftime
57+
strftime_l
5758
strptime
5859
dirname
5960
basename

src/unix/linux_like/linux/gnu/mod.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1319,6 +1319,13 @@ extern "C" {
13191319
format: *const ::c_char,
13201320
tm: *const ::tm,
13211321
) -> ::size_t;
1322+
pub fn strftime_l(
1323+
s: *mut ::c_char,
1324+
max: ::size_t,
1325+
format: *const ::c_char,
1326+
tm: *const ::tm,
1327+
locale: ::locale_t,
1328+
) -> ::size_t;
13221329
pub fn strptime(s: *const ::c_char, format: *const ::c_char, tm: *mut ::tm) -> *mut ::c_char;
13231330

13241331
pub fn dirname(path: *mut ::c_char) -> *mut ::c_char;

src/unix/linux_like/linux/musl/mod.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -778,6 +778,13 @@ extern "C" {
778778
format: *const ::c_char,
779779
tm: *const ::tm,
780780
) -> ::size_t;
781+
pub fn strftime_l(
782+
s: *mut ::c_char,
783+
max: ::size_t,
784+
format: *const ::c_char,
785+
tm: *const ::tm,
786+
locale: ::locale_t,
787+
) -> ::size_t;
781788
pub fn strptime(s: *const ::c_char, format: *const ::c_char, tm: *mut ::tm) -> *mut ::c_char;
782789

783790
pub fn dirname(path: *mut ::c_char) -> *mut ::c_char;

0 commit comments

Comments
 (0)