* Help: Alpha 6.1 Openvms problem with iargptr()
@ 1996-04-22 4:00 Cynthia Agard
0 siblings, 0 replies; only message in thread
From: Cynthia Agard @ 1996-04-22 4:00 UTC (permalink / raw)
I'm having a problem with my software. It works fine on the VAX but
goes nuts on the alpha. The alpha DEC 7000 model 640 runs openvms 6.1
It has to do with the argument passing buffer. The mishandling of
a string descriptor. Perhaps a problem with iargptr().
I have a /DECC C program calling a fortran routine.
---------------------------------------------
# define ISAMS_TYPE "ISAMS"
# define OLD "OLD"
int32 status;
int32 dummy;
int32 base_index;
int32 size;
int32 max_points;
char lid3at [17] ="ISAMS_3AT_1"; /* default 3at lid value */
char subtype [13];
typedef int32 Uars_time_tp [2];
Uars_time_tp strt_dattim;
Uars_time_tp stop_dattim;
/* String descriptor defs
------------------------- */
$DESCRIPTOR (lid3at_d, lid3at);
$DESCRIPTOR (subtype_d, subtype);
_Descrip _lid3at = &lid3at_d;
_Descrip _subtype = &subtype_d;
/* hard-coded descriptors */
$DESCRIPTOR (type_d, ISAMS_TYPE);
$DESCRIPTOR (old_new_d, OLD);
_Descrip _type = &type_d;
_Descrip _old_new = &old_new_d;
.
.
subtype_d.dsc$w_length = strlen(subtype);
lid3at_d.dsc$w_length = strlen(lid3at); /* default lid3at length */
openl3at(_type,
_subtype,
strt_dattim,
stop_dattim,
&dummy,
_old_new,
&size,
&base_index,
&max_points,
_lid3at,
&status);
When I'm in openl3at I can examine all the arguments and everything
looks good. Then I get ready to call a general argument
validation routine (not shown below). (The fortran is DEC fortran V6.1
I believe)
SUBROUTINE OPENL3AT (input_data_type,
2 input_data_subtype,
3 start_date_time,
4 stop_date_time,
5 uars_day,
6 input_old_new_flag,
7 est_file_size,
8 base_index,
9 max_points,
A input_logical_file_id,
B open_l3a_status)
IMPLICIT NONE
CHARACTER *(*) input_data_type,
& input_data_subtype
INTEGER *4 start_date_time (2),
& stop_date_time (2),
& uars_day
CHARACTER *(*) input_old_new_flag
INTEGER *4 est_file_size,
& base_index,
& max_points
CHARACTER *(*) input_logical_file_id
INTEGER *4 open_l3a_status
integer*4 ic
integer*4 argv
integer*4 argc
pointer (argp, argv)
integer*4 arglist(12) ! actual_num_args+1
.
.
.
argp = iargptr()
argc = iargcount()
do ic = 1, argc+1
arglist(ic) = argv
argp = argp + sizeof (argp) ! it incrments the pointer 8
enddo
When I examine the arg-list buffer I get:
11
2138330984
2138331024
2138331100
2138331092
1504448
65912 <*** This one is wrong it is the address of the data and
2138331352 not the descriptor address. It causes the arg
2138331376 validation program to abort
2138331192
2138331284
The problem is with old_new. How might I overcome this besides eliminating
the call to the arg validation table-driven routine. It doesn't
make sense because when I examine old_new in the subroutine it displays
correctly. I'm not sure what is going on.
Somebody suggested I play with compile options. I was trying to set up
the string descriptor in different ways to see the effects.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1996-04-22 4:00 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1996-04-22 4:00 Help: Alpha 6.1 Openvms problem with iargptr() Cynthia Agard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox