Lines Matching refs:items
328 SELinuxFreeItems(SELinuxListItemRec * items, int count)
333 freecon(items[k].octx);
334 freecon(items[k].dctx);
336 free(items);
340 SELinuxSendItemsToClient(ClientPtr client, SELinuxListItemRec * items,
355 buf[pos] = items[k].id;
360 buf[pos] = items[k].octx_len * 4;
365 buf[pos] = items[k].dctx_len * 4;
370 memcpy((char *) (buf + pos), items[k].octx, strlen(items[k].octx) + 1);
371 pos += items[k].octx_len;
372 memcpy((char *) (buf + pos), items[k].dctx, strlen(items[k].dctx) + 1);
373 pos += items[k].dctx_len;
397 SELinuxFreeItems(items, count);
406 SELinuxListItemRec *items;
417 /* Count the number of properties and allocate items */
421 items = calloc(count, sizeof(SELinuxListItemRec));
422 if (count && !items)
425 /* Fill in the items and calculate size */
430 rc = SELinuxPopulateItem(items + i, &pProp->devPrivates, id, &size);
432 SELinuxFreeItems(items, count);
438 return SELinuxSendItemsToClient(client, items, size, count);
445 SELinuxListItemRec *items;
451 /* Count the number of selections and allocate items */
455 items = calloc(count, sizeof(SELinuxListItemRec));
456 if (count && !items)
459 /* Fill in the items and calculate size */
464 rc = SELinuxPopulateItem(items + i, &pSel->devPrivates, id, &size);
466 SELinuxFreeItems(items, count);
472 return SELinuxSendItemsToClient(client, items, size, count);