From: beuter@cocoon.informatik.uni-ulm.de (Thomas Beuter)
Subject: PROBLEMS with DCE RPC on AIX (revised)
Date: Fri, 17 Mar 95 10:50:05 GMT [thread overview]
Message-ID: <1995Mar17.105005.14110@informatik.uni-ulm.de> (raw)
Hello world,
We want to develop distributed applications for RS 6000 machines based
on DCE RPC and ANSI-C. Believing the IDL compiler description (version
01.03.00.00) the IDL compiler produces ANSI-C code (header file and
stub files). But in spite of the -qlanglvl=ansi flag the xlc compiler
(version 01.03.00.33) produces an error message "Function <rpc_call>
cannot be redeclared". The reason is that data types are interpreted
differently.
example:
error_status_t rpc_call([in] long num, [out, string] char txt[20]);
The IDL compiler interprets char as unsigned char (macro idl_char ->
ndr_char -> unsigned char). Whereas the xlc compiler interprets it as
signed char. Therefore the function's declaration in the header file
(produced by idl compiler) isn`t compliant to the function`s
definition.
There are some solutions of this problem but none is really
satisfying:
- flag -qlanglvl=extended; loosing the strong type checking of
ANSI C
- using unsigned char or idl_char instead of char in the formal
parameter's definition; but some library functions
(e.g. gets) need parameter of type char. Calling such a
function with a parameter defined as unsigned char or idl_char
logically leads to an compiler error. Then I need explicit
casting; -> circumstantially
If someone knows a better solution, please contact:
beuter@informatik.uni-ulm.de
Thanks
Thomas
--
<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
Thomas Beuter
D-89069 Universitaet Ulm e-mail: beuter@informatik.uni-ulm.de
Fakultaet fuer Informatik phone: +49 731 502 4127
Datenbanken & Informationssysteme fax: +49 731 502 4134
reply other threads:[~1995-03-17 10:50 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox