Hum .. it's weird (to me :) ) so There's InetAddress in GIO the one i
was talking about and InetAddr in GNet, the good class i guess.
http://www.valadoc.org/gnet-2.0/GNet.InetAddr.html

-public void get_bytes (out string buffer) 
-public void set_bytes (char[] bytes)

a Vala rookie !



Le jeudi 11 mars 2010 à 11:36 +0100, Cyrille Colin a écrit :
> Le jeudi 11 mars 2010 à 11:13 +0100, Luca Bruno a écrit :
> 
> > It must be uchar*, it's a bug in the bindings.
> > 
> It seems to be a pointer in the main address bytes array :
> 
> This is the GLib code :
> /**
>  * g_inet_address_to_bytes:
>  * @address: a #GInetAddress
>  *
>  * Gets the raw binary address data from @address.
>  *
>  * Returns: a pointer to an internal array of the bytes in @address,
>  * which should not be modified, stored, or freed. The size of this
>  * array can be gotten with g_inet_address_get_native_size().
>  *
>  * Since: 2.22
>  */
> const guint8 *
> g_inet_address_to_bytes (GInetAddress *address)
> {
>   g_return_val_if_fail (G_IS_INET_ADDRESS (address), NULL);
> 
>   return (guint8 *)&address->priv->addr;
> }
> 
> 
> _______________________________________________
> Vala-list mailing list
> [email protected]
> http://mail.gnome.org/mailman/listinfo/vala-list


_______________________________________________
Vala-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/vala-list

Reply via email to