Bug 254361

Summary: (micro-optimization) pam_xauth.c: one call to sysconf is enough
Product: [Fedora] Fedora Reporter: Sami Farin <hvtaifwkbgefbaei>
Component: pamAssignee: Tomas Mraz <tmraz>
Status: CLOSED UPSTREAM QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: medium    
Version: rawhide   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2008-04-08 07:02:18 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
one call to sysconf is enough none

Description Sami Farin 2007-08-25 19:14:48 UTC
Description of problem:
strace output looks retarded.
8-)

8321  21:13:18.491461 getrlimit(RLIMIT_NOFILE, {rlim_cur=1024,
rlim_max=10*1024}) = 0 <0.000011>
8321  21:13:18.491513 close(622)        = -1 EBADF (Bad file descriptor) <0.000011>
8321  21:13:18.491564 getrlimit(RLIMIT_NOFILE, {rlim_cur=1024,
rlim_max=10*1024}) = 0 <0.000011>
8321  21:13:18.491616 close(623)        = -1 EBADF (Bad file descriptor) <0.000011>


Version-Release number of selected component (if applicable):


How reproducible:
always

Steps to Reproduce:
1. enable pam_xauth.so in some module
2.
3.
  
Actual results:
many calls...

Expected results:
one call...

Additional info:
after patch:
22233 22:12:56.864605 getrlimit(RLIMIT_NOFILE, {rlim_cur=1024,
rlim_max=10*1024}) = 0 <0.000013>
22233 22:12:56.864663 close(2)          = 0 <0.000013>
22233 22:12:56.864712 close(3)          = 0 <0.000014>
22233 22:12:56.864762 close(4)          = 0 <0.000013>
...

Comment 1 Sami Farin 2007-08-25 19:14:48 UTC
Created attachment 172581 [details]
one call to sysconf is enough

Comment 2 Tomas Mraz 2008-04-08 07:02:18 UTC
Applied to upstream CVS. Thank you.