mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-09 14:35:25 +00:00
util: remove virCommandPassFDGetFDIndex()
commit f9236200
removed the last use of this function, so it can be
dropped.
Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
This commit is contained in:
parent
b6705cdefb
commit
2e89805894
@ -2057,7 +2057,6 @@ virCommandNewArgs;
|
|||||||
virCommandNewVAList;
|
virCommandNewVAList;
|
||||||
virCommandNonblockingFDs;
|
virCommandNonblockingFDs;
|
||||||
virCommandPassFD;
|
virCommandPassFD;
|
||||||
virCommandPassFDGetFDIndex;
|
|
||||||
virCommandPassFDIndex;
|
virCommandPassFDIndex;
|
||||||
virCommandRawStatus;
|
virCommandRawStatus;
|
||||||
virCommandRequireHandshake;
|
virCommandRequireHandshake;
|
||||||
|
@ -1077,33 +1077,6 @@ virCommandPassFD(virCommand *cmd, int fd, unsigned int flags)
|
|||||||
virCommandPassFDIndex(cmd, fd, flags, NULL);
|
virCommandPassFDIndex(cmd, fd, flags, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* virCommandPassFDGetFDIndex:
|
|
||||||
* @cmd: pointer to virCommand
|
|
||||||
* @fd: FD to get index of
|
|
||||||
*
|
|
||||||
* Determine the index of the FD in the transfer set.
|
|
||||||
*
|
|
||||||
* Returns index >= 0 if @set contains @fd,
|
|
||||||
* -1 otherwise.
|
|
||||||
*/
|
|
||||||
int
|
|
||||||
virCommandPassFDGetFDIndex(virCommand *cmd, int fd)
|
|
||||||
{
|
|
||||||
size_t i = 0;
|
|
||||||
|
|
||||||
if (virCommandHasError(cmd))
|
|
||||||
return -1;
|
|
||||||
|
|
||||||
while (i < cmd->npassfd) {
|
|
||||||
if (cmd->passfd[i].fd == fd)
|
|
||||||
return i;
|
|
||||||
i++;
|
|
||||||
}
|
|
||||||
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* virCommandSetPidFile:
|
* virCommandSetPidFile:
|
||||||
* @cmd: the command to modify
|
* @cmd: the command to modify
|
||||||
|
@ -61,9 +61,6 @@ void virCommandPassFDIndex(virCommand *cmd,
|
|||||||
unsigned int flags,
|
unsigned int flags,
|
||||||
size_t *idx) G_GNUC_NO_INLINE;
|
size_t *idx) G_GNUC_NO_INLINE;
|
||||||
|
|
||||||
int virCommandPassFDGetFDIndex(virCommand *cmd,
|
|
||||||
int fd);
|
|
||||||
|
|
||||||
void virCommandSetPidFile(virCommand *cmd,
|
void virCommandSetPidFile(virCommand *cmd,
|
||||||
const char *pidfile) ATTRIBUTE_NONNULL(2);
|
const char *pidfile) ATTRIBUTE_NONNULL(2);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user