Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

Pointer to an unknown [struct!]

 [1/3] from: maarten:koopmans:surfnet:nl at: 6-May-2002 14:06


Hi, Tinkering with the library interface I have the following problem: I must pass in a pointer to a result structure (specifically: LDAPMessage from the Openldap libs). I have no definition for the structure however, as clients are "not supposed to directly manipulate these". I must pass it a zillion times around instead, which should not be a problem if I'd knew how to do the initial memory allocation. Anyone? --Maarten

 [2/3] from: petr:krenzelok:trz:cz at: 6-May-2002 14:56


Maarten Koopmans wrote:
>Hi, > >Tinkering with the library interface I have the following problem: > >I must pass in a pointer to a result structure (specifically: LDAPMessage from >the Openldap libs). I have no definition for the structure however, as >clients are "not supposed to directly manipulate these". >
eh, I don't understand exactly what is needed. Could you show me piece of library code or definition, please? -pekr-

 [3/3] from: cyphre::seznam::cz at: 6-May-2002 16:57


Hi Maarten, I'm not sure if I understand your problem, I don't know what should look your structure but this is little example how to get pointer to a structure: number: 123 p_str: make struct! [str [struct! [num [integer!]]]] reduce [number]
>> probe third p_str
== #{202FD800} ;this is a pointer to structure containing integer regards, Cyphre ----- Original Message ----- From: "Maarten Koopmans" <[Maarten--Koopmans--surfnet--nl]> To: <[rebol-list--rebol--com]> Cc: <[jeff--rebol--net]> Sent: Monday, May 06, 2002 2:06 PM Subject: [REBOL] Pointer to an unknown [struct!] Hi, Tinkering with the library interface I have the following problem: I must pass in a pointer to a result structure (specifically: LDAPMessage from the Openldap libs). I have no definition for the structure however, as clients are "not supposed to directly manipulate these". I must pass it a zillion times around instead, which should not be a problem if I'd knew how to do the initial memory allocation. Anyone? --Maarten