summaryrefslogtreecommitdiffstats
path: root/mono/Error.cs
blob: dab4df1ff963266ed7ab2f1bc849680940308d77 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
namespace DBus {

  using System;
  using System.Runtime.InteropServices;
  
  // FIXME add code to verify that size of DBus.Error
  // matches the C code.

  [StructLayout (LayoutKind.Sequential)]
  internal struct Error {
    internal IntPtr name;
    internal IntPtr message;
    private int dummies;
    private IntPtr padding1;

    internal void Init () {
      dbus_error_init (ref this);
    }
    
    internal void Free () {
      dbus_error_free (ref this);
    }
    
    [DllImport (DBus.Internals.DBusLibname, EntryPoint="dbus_error_init")]
    private extern static void dbus_error_init (ref Error error);
    [DllImport (DBus.Internals.DBusLibname, EntryPoint="dbus_error_free")]
    private extern static void dbus_error_free (ref Error error);
  }
}