Commit d1d4f18f authored by Stefan Walter's avatar Stefan Walter

Include gp11.h without directory prefix.

 	* pkcs11/seahorse-pkcs11-module.c: Include gp11.h without
 	directory prefix.
 
 	* pkcs11/p11.vapi:
 	* pkcs11/gp11.vapi:
 	* pkcs11/seahorse-pkcs11-source.vala: Treat attribute types
 	as ulong not uint, to prevent truncation warnings from the compiler.

svn path=/trunk/; revision=2514
parent 44595706
......@@ -56,6 +56,16 @@
* libcryptui/cryptui-key-list.c: Fix column widths, and
elipsize long text in key listing. Fixes bug #551426
Patch by Adam Schreiber.
2008-09-12 Joe Orton <jorton@redhat.com>
* pkcs11/seahorse-pkcs11-module.c: Include gp11.h without
directory prefix.
* pkcs11/p11.vapi:
* pkcs11/gp11.vapi:
* pkcs11/seahorse-pkcs11-source.vala: Treat attribute types
as ulong not uint, to prevent truncation warnings from the compiler.
2008-09-12 Stef Walter <stef@memberwebs.com>
......
......@@ -20,11 +20,11 @@ namespace GP11 {
public uchar* value;
public ulong length;
public Attribute.new_boolean (uint attr_type, bool val);
public Attribute.new_date (uint attr_type, GLib.Date date);
public Attribute.new_ulong (uint attr_type, ulong val);
public Attribute.new_string (uint attr_type, string val);
public Attribute(uint attr_type, uchar[] value);
public Attribute.new_boolean (ulong attr_type, bool val);
public Attribute.new_date (ulong attr_type, GLib.Date date);
public Attribute.new_ulong (ulong attr_type, ulong val);
public Attribute.new_string (ulong attr_type, string val);
public Attribute(ulong attr_type, uchar[] value);
public bool get_boolean();
public ulong get_ulong();
public string get_string();
......@@ -38,16 +38,16 @@ namespace GP11 {
public uint count { get; }
public Attribute at(uint index);
public void add(Attribute attr);
public void add_data(uint attr_type, uchar[] value);
public void add_boolean(uint attr_type, bool val);
public void add_date (uint attr_type, GLib.Date date);
public void add_ulong (uint attr_type, ulong val);
public void add_string (uint attr_type, string val);
public weak Attribute? find(uint attr_type);
public bool find_boolean(uint attr_type, out bool val);
public bool find_ulong(uint attr_type, out ulong val);
public bool find_string(uint attr_type, out string val);
public bool find_date(uint attr_type, out GLib.Date date);
public void add_data(ulong attr_type, uchar[] value);
public void add_boolean(ulong attr_type, bool val);
public void add_date (ulong attr_type, GLib.Date date);
public void add_ulong (ulong attr_type, ulong val);
public void add_string (ulong attr_type, string val);
public weak Attribute? find(ulong attr_type);
public bool find_boolean(ulong attr_type, out bool val);
public bool find_ulong(ulong attr_type, out ulong val);
public bool find_string(ulong attr_type, out string val);
public bool find_date(ulong attr_type, out GLib.Date date);
}
[CCode (dup_function = "gp11_module_info_dup", free_function = "gp11_module_info_free")]
......@@ -192,16 +192,16 @@ namespace GP11 {
public void set_attributes_finish(GLib.AsyncResult result) throws GLib.Error;
[CCode (cname = "gp11_object_get_full")]
public Attributes get_attributes(uint[] attr_types, GLib.Cancellable? cancellable = null) throws GLib.Error;
public Attributes get_attributes(ulong[] attr_types, GLib.Cancellable? cancellable = null) throws GLib.Error;
[CCode (cname = "gp11_object_get_async")]
public void get_attributes_async(uint[] attr_types, GLib.Cancellable? cancellable, GLib.AsyncReadyCallback callback);
public void get_attributes_async(ulong[] attr_types, GLib.Cancellable? cancellable, GLib.AsyncReadyCallback callback);
[CCode (cname = "gp11_object_get_finish")]
public Attributes get_attributes_finish(GLib.AsyncResult result) throws GLib.Error;
[CCode (cname = "gp11_object_get_one_full")]
public Attribute get_attribute(uint attr_type, GLib.Cancellable? cancellable = null) throws GLib.Error;
public Attribute get_attribute(ulong attr_type, GLib.Cancellable? cancellable = null) throws GLib.Error;
[CCode (cname = "gp11_object_get_one_async")]
public void get_attribute_async(uint attr_type, GLib.Cancellable? cancellable, GLib.AsyncReadyCallback callback);
public void get_attribute_async(ulong attr_type, GLib.Cancellable? cancellable, GLib.AsyncReadyCallback callback);
[CCode (cname = "gp11_object_get_one_finish")]
public Attribute get_attribute_finish(GLib.AsyncResult result) throws GLib.Error;
}
......
[CCode (cheader_filename = "pkcs11.h,pkcs11g.h", cprefix = "", lower_case_cprefix = "")]
namespace P11 {
const uint CKA_CLASS;
const uint CKA_END_DATE;
const uint CKA_EXTRACTABLE;
const uint CKA_GNOME_IMPORT_OBJECTS;
const uint CKA_GNOME_IMPORT_TOKEN;
const uint CKA_GNOME_USER_TRUST;
const uint CKA_ID;
const uint CKA_LABEL;
const uint CKA_START_DATE;
const uint CKA_TOKEN;
const uint CKA_VALUE;
const ulong CKA_CLASS;
const ulong CKA_END_DATE;
const ulong CKA_EXTRACTABLE;
const ulong CKA_GNOME_IMPORT_OBJECTS;
const ulong CKA_GNOME_IMPORT_TOKEN;
const ulong CKA_GNOME_USER_TRUST;
const ulong CKA_ID;
const ulong CKA_LABEL;
const ulong CKA_START_DATE;
const ulong CKA_TOKEN;
const ulong CKA_VALUE;
const ulong CKO_DATA;
const ulong CKO_CERTIFICATE;
......
......@@ -27,7 +27,8 @@
#include "seahorse-gconf.h"
#include "seahorse-util.h"
#include "gp11/gp11.h"
#include <gp11.h>
void
seahorse_pkcs11_module_init (void)
{
......
......@@ -261,7 +261,7 @@ static GType seahorse_pkcs11_source_remover_get_type (void);
static gpointer seahorse_pkcs11_source_parent_class = NULL;
static void seahorse_pkcs11_source_finalize (GObject * obj);
static const guint SEAHORSE_PKCS11_ATTRIBUTE_TYPES[] = {CKA_LABEL, CKA_ID, CKA_CLASS, CKA_TOKEN, CKA_GNOME_USER_TRUST, CKA_START_DATE, CKA_END_DATE, CKA_EXTRACTABLE};
static const gulong SEAHORSE_PKCS11_ATTRIBUTE_TYPES[] = {CKA_LABEL, CKA_ID, CKA_CLASS, CKA_TOKEN, CKA_GNOME_USER_TRUST, CKA_START_DATE, CKA_END_DATE, CKA_EXTRACTABLE};
/* ---------------------------------------------------------------------------------
......
......@@ -3,7 +3,7 @@
namespace Seahorse.Pkcs11 {
static const uint[] ATTRIBUTE_TYPES = {
static const ulong[] ATTRIBUTE_TYPES = {
P11.CKA_LABEL,
P11.CKA_ID,
P11.CKA_CLASS,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment