Usenet comp.unix.osf.misc (1992-2004)
 help / color / mirror / Atom feed
From: tomj@gradient.com (Tom Jordahl)
Subject: Re: PROBLEMS with DCE RPC on AIX
Date: 16 Mar 1995 20:31:48 GMT	[thread overview]
Message-ID: <3ka77k$to@gradient.gradient.com> (raw)
In-Reply-To: 1995Mar16.112111.26682@informatik.uni-ulm.de

In article <1995Mar16.112111.26682@informatik.uni-ulm.de>,
Thomas Beuter <beuter@cocoon.informatik.uni-ulm.de> wrote:
>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

Thomas,

This looks like it was a mistake that we tried to correct in DCE 1.1.
You are probably using an IBM DCE based on DCE 1.0.3.

I'm not sure if this will be much help, 
but in <dce/idlbase.h> in the 1.1 source if the following:

/*
 * when compiling DCE programs and/or libraries, we want the base type
 * of idl_char to be "unsigned char" (IDL doesn't support signed chars).
 * However, we compiling external programs, we want idl_char to have
 * the char type native to the platform on which the program is being
 * compiled. So ... use a macro that should only be defined if we
 * are building the RPC runtime of the IDL compiler.
 */

#ifndef IDL_CHAR_IS_CHAR
typedef unsigned char idl_char ;
#else
typedef char idl_char ;
#endif /* idl_char */

You may be able to retrofit you header file with this change.

I would certainly contact IBM and ask them to investigate
patching their DCE product with a similar fix if their compiler 
chokes in your (not uncommon?) situation.

-- 
Tom Jordahl                                       Internet: tom_j@gradient.com
Gradient Technologies Inc.                        DCE development


  reply	other threads:[~1995-03-16 20:31 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1995-03-16 11:21 PROBLEMS with DCE RPC on AIX Thomas Beuter
1995-03-16 20:31 ` Tom Jordahl [this message]
1995-03-17  5:23 ` Gregory_Brail
1995-03-17 22:27 ` Trey Thompson
1995-03-21  2:56 ` Bill Janssen
1995-03-21 15:17   ` Rich Salz
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