Navigation Menu

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patch:pp_sys.c _58 QNX #275

Closed
p5pRT opened this issue Jul 28, 1999 · 1 comment
Closed

Patch:pp_sys.c _58 QNX #275

p5pRT opened this issue Jul 28, 1999 · 1 comment

Comments

@p5pRT
Copy link

p5pRT commented Jul 28, 1999

Migrated from rt.perl.org#1097 (status was 'resolved')

Searchable as RT1097$

@p5pRT
Copy link
Author

p5pRT commented Jul 28, 1999

From allen@huarp.harvard.edu

  defined(HAS_GETSPNAM) && ! defined(HAS_GETSPENT)

which is true for QNX4.

exit 0

*** perl5.005_58.ORIG/pp_sys.c Tue Jul 27 00​:47​:13 1999
--- perl5.005_58/pp_sys.c Wed Jul 28 12​:34​:58 1999
***************
*** 4617,4623 ****
  register SV *sv;
  struct passwd *pwent;
  STRLEN n_a;
! #ifdef HAS_GETSPENT
  struct spwd *spwent = NULL;
  #endif
 
--- 4617,4623 ----
  register SV *sv;
  struct passwd *pwent;
  STRLEN n_a;
! #if defined(HAS_GETSPENT) || defined(HAS_GETSPNAM)
  struct spwd *spwent = NULL;
  #endif
 
***************
*** 4639,4646 ****
--- 4639,4648 ----
  spwent = getspnam(pwent->pw_name);
  }
  # endif
+ # ifdef HAS_GETSPENT
  else
  spwent = (struct spwd *)getspent();
+ # endif
  #endif
 
  EXTEND(SP, 10);
***************
*** 4661,4667 ****
 
  PUSHs(sv = sv_mortalcopy(&PL_sv_no));
  #ifdef PWPASSWD
! # ifdef HAS_GETSPENT
  if (spwent)
  sv_setpv(sv, spwent->sp_pwdp);
  else
--- 4663,4669 ----
 
  PUSHs(sv = sv_mortalcopy(&PL_sv_no));
  #ifdef PWPASSWD
! # if defined(HAS_GETSPENT) || defined(HAS_GETSPNAM)
  if (spwent)
  sv_setpv(sv, spwent->sp_pwdp);
  else

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant