Skip to content

Commit

Permalink
Use explicit pointer cast for zopnnd call in zfiobf.c
Browse files Browse the repository at this point in the history
The first argument in ZOPNND() should really be declared as a `char *`.
However it is a SPP called function and therefore limited to the SPP
data types; so the first argument is declared as `PKG_CHAR *` (which
is a `short int`). Therefore we need to cast it when called from C.
  • Loading branch information
olebole committed Apr 15, 2024
1 parent 0f82aa4 commit b40f5d6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion unix/os/zfiobf.c
Original file line number Diff line number Diff line change
Expand Up @@ -767,7 +767,7 @@ vm_connect (void)
"vmclient (%s): open server connection `%s' -> ",
vm_client, osfn);

ZOPNND (osfn, &acmode, &fd);
ZOPNND ((PKCHAR *)osfn, &acmode, &fd);
if (fd == XERR) {
if (vm_debug)
fprintf (stderr, "failed\n");
Expand Down

0 comments on commit b40f5d6

Please sign in to comment.