view cinst/nss-secitemlist.h @ 372:6cc124e79066

Add save/load unselected and add role enumerator Explicitly naming the roles avoids confusion and makes the code more readable
author Andre Heinecke <andre.heinecke@intevation.de>
date Tue, 15 Apr 2014 11:56:29 +0200
parents 809eaca3898c
children 17e1c8f37d72
line wrap: on
line source
#ifndef NSS_SECITEMLIST_H
#define NSS_SECITEMLIST_H

/**
 * @file
 * @brief Functions to handle lists of NSS SECItem-s.
 */

#include <seccomon.h>
#include "strhelp.h"

struct seciteml {
  SECItem *item;
  struct seciteml *next;
};

/**
 * @brief Type for SECItem lists
 */
typedef struct seciteml seciteml_t;

/**
 * @brief Prepend a new SECItem to list
 *
 * The data will be copied.
 * @param[inout] list pointer to the list to which the item will be added.
 * @param[in] item the SECItem to add to the list.
 */
void seciteml_push (seciteml_t **list, SECItem *item);

/**
 * @brief Remove and return first SECItem from list
 *
 * @param[inout] list pointer to the list to which the item will be added.
 * @retruns the removed item, or NULL if list is empty.
 * The caller shoud free this item after use.
 */
SECItem *seciteml_pop (seciteml_t **list);

#endif

http://wald.intevation.org/projects/trustbridge/