Skip to content

Commit

Permalink
(DL_SYSDEP_OSCHECK): If GLRO(dl_osversion) has been already set to a …
Browse files Browse the repository at this point in the history
…value smaller than _dl_discover_osversion (), don't overwrite it here.
  • Loading branch information
Ulrich Drepper committed May 30, 2005
1 parent 8074c5c commit 609b254
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion sysdeps/unix/sysv/linux/dl-osinfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,9 @@ _dl_discover_osversion (void)
int version = _dl_discover_osversion (); \
if (__builtin_expect (version >= 0, 1)) \
{ \
GLRO(dl_osversion) = version; \
if (__builtin_expect (GLRO(dl_osversion) == 0, 1) \
|| GLRO(dl_osversion) > version) \
GLRO(dl_osversion) = version; \
\
/* Now we can test with the required version. */ \
if (__LINUX_KERNEL_VERSION > 0 && version < __LINUX_KERNEL_VERSION) \
Expand Down

0 comments on commit 609b254

Please sign in to comment.