Ed Schouten
e2f6816100
Reimplement dirname(3) to be thread-safe.
...
Now that we've updated the prototypes of the basename(3) and dirname(3)
functions to conform to POSIX, let's go ahead and reimplement dirname(3)
in such a way that it's thread-safe, but also guaranteed to succeed. C
libraries like glibc, musl and the one that's part of Solaris already
follow such an approach.
Move the existing implementation to another source file,
freebsd11_dirname.c to keep existing users of the API that pass in a
constant string happy, using symbol versioning.
Put a new version of the function in dirname.c, obtained from CloudABI's
C library. This version scans through the pathname string from left to
right, normalizing it, while discarding the last pathname component.
Reviewed by: emaste, jilles
Differential Revision: https://reviews.freebsd.org/D7355
2016-08-12 07:03:58 +00:00
..
2016-05-04 23:20:53 +00:00
2016-07-08 01:47:01 +00:00
2016-05-22 08:20:30 +00:00
2016-02-04 21:16:35 +00:00
2016-02-05 01:03:38 +00:00
2016-06-22 07:49:59 +00:00
2016-02-04 21:16:35 +00:00
2016-02-04 21:16:35 +00:00
2016-06-03 19:25:30 +00:00
2016-02-04 21:16:35 +00:00
2016-05-04 22:34:11 +00:00
2016-05-16 15:42:59 +00:00
2016-02-04 21:16:35 +00:00
2016-05-13 21:17:49 +00:00
2016-02-04 21:16:35 +00:00
2016-08-12 07:03:58 +00:00
2015-06-13 19:20:56 +00:00
2016-05-29 06:20:15 +00:00
2016-02-04 21:16:35 +00:00
2016-05-24 00:57:11 +00:00
2016-06-13 00:03:55 +00:00
2016-06-14 16:55:05 +00:00
2016-02-04 21:16:35 +00:00
2016-05-25 07:26:22 +00:00
2016-05-18 06:01:18 +00:00
2016-08-10 15:16:28 +00:00
2016-04-26 01:20:16 +00:00
2016-06-29 11:48:42 +00:00
2016-04-27 16:33:17 +00:00
2016-06-03 19:25:30 +00:00
2016-04-04 23:55:32 +00:00
2016-02-04 21:16:35 +00:00
2016-03-02 16:14:46 +00:00
2016-04-21 12:58:29 +00:00
2016-05-01 19:37:33 +00:00
2016-02-04 21:16:35 +00:00
2016-04-21 12:58:29 +00:00
2016-06-05 23:05:14 +00:00
2016-02-04 21:16:35 +00:00
2016-02-04 21:16:35 +00:00
2016-02-04 21:16:35 +00:00
2016-05-31 08:27:39 +00:00
2016-03-02 16:14:46 +00:00
2016-02-04 21:16:35 +00:00
2016-04-19 15:18:31 +00:00
2016-05-01 19:37:33 +00:00
2015-11-25 19:10:28 +00:00
2016-04-18 15:08:31 +00:00
2016-02-04 21:16:35 +00:00
2016-05-01 19:37:33 +00:00
2016-07-18 01:55:25 +00:00
2016-02-04 21:16:35 +00:00
2016-02-04 21:16:35 +00:00
2016-06-27 06:41:11 +00:00
2016-07-21 18:47:51 +00:00
2016-02-10 04:20:39 +00:00
2016-03-02 16:14:46 +00:00
2016-05-12 03:53:20 +00:00
2016-05-20 19:30:52 +00:00
2016-02-04 21:16:35 +00:00
2016-02-04 21:16:35 +00:00
2016-02-04 21:16:35 +00:00
2016-02-04 21:16:35 +00:00
2016-05-04 23:20:53 +00:00
2016-02-04 21:16:35 +00:00
2016-02-04 21:16:35 +00:00
2016-06-14 16:55:05 +00:00
2016-08-09 19:44:33 +00:00
2016-02-16 02:14:30 +00:00
2016-03-02 16:14:46 +00:00
2016-05-01 19:37:33 +00:00
2016-08-02 18:13:50 +00:00
2016-02-04 21:16:35 +00:00
2016-05-24 11:44:43 +00:00
2016-05-11 14:37:33 +00:00
2016-03-02 16:14:46 +00:00
2016-07-14 23:28:53 +00:00
2016-07-30 03:05:23 +00:00
2016-02-04 21:16:35 +00:00
2016-05-01 19:37:33 +00:00
2016-03-02 16:14:46 +00:00
2016-02-04 21:16:35 +00:00
2016-03-02 16:14:46 +00:00
2016-03-02 16:14:46 +00:00
2016-02-04 21:16:35 +00:00
2016-05-20 05:33:26 +00:00
2016-02-04 21:16:35 +00:00
2016-02-04 21:16:35 +00:00
2016-04-04 23:55:32 +00:00
2016-02-04 21:16:35 +00:00
2016-02-04 21:16:35 +00:00
2016-08-07 01:29:55 +00:00
2016-02-04 21:16:35 +00:00
2016-06-04 14:57:25 +00:00
2016-05-18 19:59:05 +00:00
2016-02-04 21:16:35 +00:00
2016-02-04 21:16:35 +00:00
2016-03-14 18:54:29 +00:00
2016-06-24 10:55:14 +00:00
2016-04-11 15:24:59 +00:00
2016-05-18 15:25:45 +00:00
2016-04-13 16:19:50 +00:00
2016-05-01 19:37:33 +00:00
2016-02-04 21:16:35 +00:00
2016-05-29 01:43:28 +00:00
2016-02-04 21:16:35 +00:00
2016-04-16 02:32:12 +00:00
2016-04-04 23:55:32 +00:00
2016-08-08 17:59:59 +00:00
2016-05-09 22:21:09 +00:00
2016-05-04 23:20:53 +00:00
2016-06-07 16:31:03 +00:00