aboutsummaryrefslogtreecommitdiff
path: root/time/ftime.c
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2020-10-19 09:35:58 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2020-10-27 09:54:13 -0300
commit30a0b167d347dd80807d167ee85bf58264fb8b76 (patch)
treee14269caa56674542161206bf5fe8861c618163c /time/ftime.c
parent6f21b0c5edcdb36a8b094f2c2a2365d73caeeb72 (diff)
downloadglibc-30a0b167d347dd80807d167ee85bf58264fb8b76.tar
glibc-30a0b167d347dd80807d167ee85bf58264fb8b76.tar.gz
glibc-30a0b167d347dd80807d167ee85bf58264fb8b76.tar.bz2
glibc-30a0b167d347dd80807d167ee85bf58264fb8b76.zip
Reinstate ftime and add deprecate message on ftime usage
This patch revert "Move ftime to a compatibility symbol" (commit 14633d3e568eb9770a7e5046eff257113e0453fb). Checked on x86_64-linux-gnu and i686-linux-gnu.
Diffstat (limited to 'time/ftime.c')
-rw-r--r--time/ftime.c20
1 files changed, 3 insertions, 17 deletions
diff --git a/time/ftime.c b/time/ftime.c
index be3295ef76..70a2590c17 100644
--- a/time/ftime.c
+++ b/time/ftime.c
@@ -16,23 +16,12 @@
License along with the GNU C Library; if not, see
<https://www.gnu.org/licenses/>. */
-#include <shlib-compat.h>
-
-#if SHLIB_COMPAT (libc, GLIBC_2_0, GLIBC_2_33)
-
+#include <features.h>
+#include <sys/timeb.h>
#include <time.h>
-struct timeb
- {
- time_t time; /* Seconds since epoch, as from `time'. */
- unsigned short int millitm; /* Additional milliseconds. */
- short int timezone; /* Minutes west of GMT. */
- short int dstflag; /* Nonzero if Daylight Savings Time used. */
- };
-
int
-attribute_compat_text_section
-__ftime (struct timeb *timebuf)
+ftime (struct timeb *timebuf)
{
struct timespec ts;
__clock_gettime (CLOCK_REALTIME, &ts);
@@ -43,6 +32,3 @@ __ftime (struct timeb *timebuf)
timebuf->dstflag = 0;
return 0;
}
-
-compat_symbol (libc, __ftime, ftime, GLIBC_2_0);
-#endif