summaryrefslogtreecommitdiff
path: root/perlio.c
diff options
context:
space:
mode:
authorSpider Boardman <spider@orb.nashua.nh.us>1999-08-03 10:25:00 -0400
committerJarkko Hietaniemi <jhi@iki.fi>1999-08-03 19:52:38 +0000
commit961e40eebbdecbc4e587e5c0fd92623798217256 (patch)
tree88a8676f080797ff8d6fe8e0bf367b40da674f79 /perlio.c
parent1948c06a2e905ba4a6b769a97c8eb3166587dc8e (diff)
downloadperl-961e40eebbdecbc4e587e5c0fd92623798217256.tar.gz
The "-Dusethreads -Duseperlio" combination failed.
To: perl5-porters@perl.org Subject: [ID 19990803.007] Not OK: perl 5.00560 on alpha-dec_osf-thread 4.0 (UNINSTALLED) Message-Id: <199908031825.OAA29254@leggy.zk3.dec.com> See also change #3912. p4raw-link: @3912 (not found) p4raw-id: //depot/cfgperl@3911
Diffstat (limited to 'perlio.c')
-rw-r--r--perlio.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/perlio.c b/perlio.c
index 9230b0c004..a2e979ab6f 100644
--- a/perlio.c
+++ b/perlio.c
@@ -143,7 +143,8 @@ PerlIO_canset_cnt(PerlIO *f)
void
PerlIO_set_cnt(PerlIO *f, int cnt)
{
- if (cnt < -1 && ckWARN_s(WARN_INTERNAL))
+ dTHX;
+ if (cnt < -1 && ckWARN_d(WARN_INTERNAL))
Perl_warner(aTHX_ WARN_INTERNAL, "Setting cnt to %d\n",cnt);
#if defined(USE_STDIO_PTR) && defined(STDIO_CNT_LVALUE)
FILE_cnt(f) = cnt;
@@ -157,21 +158,24 @@ void
PerlIO_set_ptrcnt(PerlIO *f, STDCHAR *ptr, int cnt)
{
#ifdef FILE_bufsiz
+ dTHX;
STDCHAR *e = FILE_base(f) + FILE_bufsiz(f);
int ec = e - ptr;
- if (ptr > e + 1 && ckWARN_s(WARN_INTERNAL))
+ if (ptr > e + 1 && ckWARN_d(WARN_INTERNAL))
Perl_warner(aTHX_ WARN_INTERNAL, "Setting ptr %p > end+1 %p\n", ptr, e + 1);
- if (cnt != ec && ckWARN_s(WARN_INTERNAL))
+ if (cnt != ec && ckWARN_d(WARN_INTERNAL))
Perl_warner(aTHX_ WARN_INTERNAL, "Setting cnt to %d, ptr implies %d\n",cnt,ec);
#endif
#if defined(USE_STDIO_PTR) && defined(STDIO_PTR_LVALUE)
FILE_ptr(f) = ptr;
#else
+ dTHX;
Perl_croak(aTHX_ "Cannot set 'ptr' of FILE * on this system");
#endif
#if defined(USE_STDIO_PTR) && defined(STDIO_CNT_LVALUE)
FILE_cnt(f) = cnt;
#else
+ dTHX;
Perl_croak(aTHX_ "Cannot set 'cnt' of FILE * on this system");
#endif
}
@@ -183,6 +187,7 @@ PerlIO_get_cnt(PerlIO *f)
#ifdef FILE_cnt
return FILE_cnt(f);
#else
+ dTHX;
Perl_croak(aTHX_ "Cannot get 'cnt' of FILE * on this system");
return -1;
#endif
@@ -195,6 +200,7 @@ PerlIO_get_bufsiz(PerlIO *f)
#ifdef FILE_bufsiz
return FILE_bufsiz(f);
#else
+ dTHX;
Perl_croak(aTHX_ "Cannot get 'bufsiz' of FILE * on this system");
return -1;
#endif
@@ -207,6 +213,7 @@ PerlIO_get_ptr(PerlIO *f)
#ifdef FILE_ptr
return FILE_ptr(f);
#else
+ dTHX;
Perl_croak(aTHX_ "Cannot get 'ptr' of FILE * on this system");
return NULL;
#endif
@@ -219,6 +226,7 @@ PerlIO_get_base(PerlIO *f)
#ifdef FILE_base
return FILE_base(f);
#else
+ dTHX;
Perl_croak(aTHX_ "Cannot get 'base' of FILE * on this system");
return NULL;
#endif
@@ -284,6 +292,7 @@ PerlIO_getname(PerlIO *f, char *buf)
#ifdef VMS
return fgetname(f,buf);
#else
+ dTHX;
Perl_croak(aTHX_ "Don't know how to get file name");
return NULL;
#endif