This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug dynamic-link/21502] New: Excessive memory allocation due to LD_HWCAP_MASK


https://sourceware.org/bugzilla/show_bug.cgi?id=21502

            Bug ID: 21502
           Summary: Excessive memory allocation due to LD_HWCAP_MASK
           Product: glibc
           Version: 2.26
            Status: NEW
          Severity: normal
          Priority: P2
         Component: dynamic-link
          Assignee: siddhesh at sourceware dot org
          Reporter: siddhesh at sourceware dot org
  Target Milestone: ---

It was discovered that setting LD_HWCAP_MASK to a large numeric value results
in significant memory allocation in the dynamic linker and sometimes results in
malloc failure, causing the program to crash.  A simple test like this
demonstrates the problem:

LD_HWCAP_MASK=0xffffffffffffffff /bin/true

On a system with constrained overcommit, this should fail with the following
error:

/bin/true: error while loading shared libraries: cannot create capability list:
Cannot allocate memory

or at least take a very long time to finish.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]