Lines Matching refs:item
262 struct kdbus_item *item;
279 KDBUS_ITEM_FOREACH(item, name, items) {
280 if (item->type == KDBUS_ITEM_OWNED_NAME) {
281 if (service_name_is_valid(item->name.name)) {
282 r = strv_extend(x, item->name.name);
403 struct kdbus_item *item;
411 KDBUS_ITEM_FOREACH(item, info, items) {
413 switch (item->type) {
417 if (mask & SD_BUS_CREDS_PID && item->pids.pid > 0) {
418 c->pid = (pid_t) item->pids.pid;
422 if (mask & SD_BUS_CREDS_TID && item->pids.tid > 0) {
423 c->tid = (pid_t) item->pids.tid;
428 if (item->pids.ppid > 0) {
429 c->ppid = (pid_t) item->pids.ppid;
431 } else if (item->pids.pid == 1) {
451 if (mask & SD_BUS_CREDS_UID && (uid_t) item->creds.uid != UID_INVALID) {
452 c->uid = (uid_t) item->creds.uid;
456 if (mask & SD_BUS_CREDS_EUID && (uid_t) item->creds.euid != UID_INVALID) {
457 c->euid = (uid_t) item->creds.euid;
461 if (mask & SD_BUS_CREDS_SUID && (uid_t) item->creds.suid != UID_INVALID) {
462 c->suid = (uid_t) item->creds.suid;
466 if (mask & SD_BUS_CREDS_FSUID && (uid_t) item->creds.fsuid != UID_INVALID) {
467 c->fsuid = (uid_t) item->creds.fsuid;
471 if (mask & SD_BUS_CREDS_GID && (gid_t) item->creds.gid != GID_INVALID) {
472 c->gid = (gid_t) item->creds.gid;
476 if (mask & SD_BUS_CREDS_EGID && (gid_t) item->creds.egid != GID_INVALID) {
477 c->egid = (gid_t) item->creds.egid;
481 if (mask & SD_BUS_CREDS_SGID && (gid_t) item->creds.sgid != GID_INVALID) {
482 c->sgid = (gid_t) item->creds.sgid;
486 if (mask & SD_BUS_CREDS_FSGID && (gid_t) item->creds.fsgid != GID_INVALID) {
487 c->fsgid = (gid_t) item->creds.fsgid;
495 r = free_and_strdup(&c->comm, item->str);
505 r = free_and_strdup(&c->tid_comm, item->str);
515 r = free_and_strdup(&c->exe, item->str);
525 c->cmdline_size = item->size - offsetof(struct kdbus_item, data);
526 c->cmdline = memdup(item->data, c->cmdline_size);
540 r = free_and_strdup(&c->cgroup, item->str);
561 if (item->caps.last_cap != cap_last_cap() ||
562 item->size - offsetof(struct kdbus_item, caps.caps) < DIV_ROUND_UP(item->caps.last_cap, 32U) * 4 * 4)
565 c->capability = memdup(item->caps.caps, item->size - offsetof(struct kdbus_item, caps.caps));
575 r = free_and_strdup(&c->label, item->str);
585 c->audit_session_id = (uint32_t) item->audit.sessionid;
590 c->audit_login_uid = (uid_t) item->audit.loginuid;
596 if ((mask & SD_BUS_CREDS_WELL_KNOWN_NAMES) && service_name_is_valid(item->name.name)) {
597 r = strv_extend(&c->well_known_names, item->name.name);
607 r = free_and_strdup(&c->description, item->str);
620 n = (item->size - offsetof(struct kdbus_item, data64)) / sizeof(uint64_t);
626 g[i] = item->data64[i];
1054 struct kdbus_item *item;
1125 item = m->items;
1126 item->size =
1131 item->name_change.old_id.id = old_owner_id;
1132 item->name_change.new_id.id = new_owner_id;
1135 memcpy(item->name_change.name, name, l);
1140 item->type = KDBUS_ITEM_NAME_ADD;
1150 item->type = KDBUS_ITEM_NAME_REMOVE;
1163 item->type = KDBUS_ITEM_NAME_CHANGE;
1185 item = m->items;
1186 item->size =
1189 item->id_change.id = name_id;
1194 item->type = KDBUS_ITEM_ID_ADD;
1196 item->id_change.id = new_owner_id;
1206 item->type = KDBUS_ITEM_ID_REMOVE;
1208 item->id_change.id = old_owner_id;
1226 struct kdbus_item *item;
1387 item = m->items;
1390 item->size = offsetof(struct kdbus_item, id) + sizeof(uint64_t);
1391 item->type = KDBUS_ITEM_ID;
1392 item->id = src_id;
1393 item = KDBUS_ITEM_NEXT(item);
1397 item->size = offsetof(struct kdbus_item, id) + sizeof(uint64_t);
1398 item->type = KDBUS_ITEM_DST_ID;
1399 item->id = dst_id;
1400 item = KDBUS_ITEM_NEXT(item);
1404 item->size = offsetof(struct kdbus_item, data64) + bus->bloom_size;
1405 item->type = KDBUS_ITEM_BLOOM_MASK;
1406 memcpy(item->data64, bloom, bus->bloom_size);
1407 item = KDBUS_ITEM_NEXT(item);
1411 item->size = offsetof(struct kdbus_item, str) + sender_length + 1;
1412 item->type = KDBUS_ITEM_NAME;
1413 memcpy(item->str, sender, sender_length + 1);