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

more problems with embedded API #5556

Closed
p5pRT opened this issue Jun 10, 2002 · 3 comments
Closed

more problems with embedded API #5556

p5pRT opened this issue Jun 10, 2002 · 3 comments
Labels

Comments

@p5pRT
Copy link

p5pRT commented Jun 10, 2002

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

Searchable as RT9523$

@p5pRT
Copy link
Author

p5pRT commented Jun 10, 2002

From Kevin.Regan@netiq.com

It seems that doing the following​:

PerlInterpreter* interpreter = perl_alloc();
perl_construct( interpreter );
perl_destruct( interpreter );

does not work. The example above dies in perl_destruct(). Should this be
allowed (no call to perl_parse() before calling perl_destruct())?

Sincerely,
Kevin Regan

Kevin Regan
NetIQ Corporation (www.netiq.com)
Technical Lead
Houston UNIX Team
Office​: 2200
Phone​: 713-548-1767

@p5pRT
Copy link
Author

p5pRT commented Jul 5, 2016

From @dcollinsn

  $ cat test.c
  #include <EXTERN.h> /* from the Perl distribution */
  #include <perl.h> /* from the Perl distribution */
  static PerlInterpreter *my_perl; /*** The Perl interpreter ***/
  int main(int argc, char **argv, char **env)
  {
  PERL_SYS_INIT3(&argc,&argv,&env);
  my_perl = perl_alloc();
  perl_construct(my_perl);
  perl_destruct(my_perl);
  perl_free(my_perl);
  PERL_SYS_TERM();
  printf("still alive\n");
  exit(0);
  }
  $ gcc-6 test.c -lperl -I. -L. -lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -lquadmath
  $ ./a.out
  still alive

Marking resolved, as there is no evidence that this is a problem - though, don't take this as an assertion that this code is supported, or does anything meaningful.

@p5pRT
Copy link
Author

p5pRT commented Jul 5, 2016

@dcollinsn - Status changed from 'open' to 'resolved'

@p5pRT p5pRT closed this as completed Jul 5, 2016
@p5pRT p5pRT added the XS label Oct 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant