Print this page
Bump Apache dependency to Apache 2
*** 18,36 ****
*
* CDDL HEADER END
*/
/*
* Copyright 2008 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*
*/
/* $Id: attribute.c 157 2006-04-26 15:07:55Z ktou $ */
- #pragma ident "%Z%%M% %I% %E% SMI"
-
/*LINTLIBRARY*/
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
--- 18,35 ----
*
* CDDL HEADER END
*/
/*
+ * Copyright 2012 Nexenta Systems, Inc. All rights reserved.
* Copyright 2008 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*
*/
/* $Id: attribute.c 157 2006-04-26 15:07:55Z ktou $ */
/*LINTLIBRARY*/
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
*** 201,211 ****
return (result);
}
static papi_attribute_t *
! papiAttributeAlloc(char *name, papi_attribute_value_type_t type)
{
papi_attribute_t *result = NULL;
if ((result = calloc(1, sizeof (*result))) != NULL) {
result->name = strdup(name);
--- 200,210 ----
return (result);
}
static papi_attribute_t *
! papiAttributeAlloc(const char *name, papi_attribute_value_type_t type)
{
papi_attribute_t *result = NULL;
if ((result = calloc(1, sizeof (*result))) != NULL) {
result->name = strdup(name);
*** 236,246 ****
return (PAPI_OK);
}
papi_status_t
papiAttributeListAddValue(papi_attribute_t ***list, int flgs,
! char *name, papi_attribute_value_type_t type,
papi_attribute_value_t *value)
{
papi_status_t result;
int flags = flgs;
papi_attribute_t *attribute = NULL;
--- 235,245 ----
return (PAPI_OK);
}
papi_status_t
papiAttributeListAddValue(papi_attribute_t ***list, int flgs,
! const char *name, papi_attribute_value_type_t type,
papi_attribute_value_t *value)
{
papi_status_t result;
int flags = flgs;
papi_attribute_t *attribute = NULL;
*** 316,326 ****
return (papiAttributeListAddValue(list, flags, name, PAPI_INTEGER, &v));
}
papi_status_t
papiAttributeListAddBoolean(papi_attribute_t ***list, int flags,
! char *name, char boolean)
{
papi_attribute_value_t v;
v.boolean = boolean;
return (papiAttributeListAddValue(list, flags, name, PAPI_BOOLEAN, &v));
--- 315,325 ----
return (papiAttributeListAddValue(list, flags, name, PAPI_INTEGER, &v));
}
papi_status_t
papiAttributeListAddBoolean(papi_attribute_t ***list, int flags,
! const char *name, char boolean)
{
papi_attribute_value_t v;
v.boolean = boolean;
return (papiAttributeListAddValue(list, flags, name, PAPI_BOOLEAN, &v));
*** 400,410 ****
return (PAPI_OK);
}
papi_attribute_t *
! papiAttributeListFind(papi_attribute_t **list, char *name)
{
int i;
if ((list == NULL) || (name == NULL))
return (NULL);
--- 399,409 ----
return (PAPI_OK);
}
papi_attribute_t *
! papiAttributeListFind(papi_attribute_t **list, const char *name)
{
int i;
if ((list == NULL) || (name == NULL))
return (NULL);