libssh2_channel_get_exit_signal(3) [debian man page]
libssh2_channel_get_exit_signal(3) libssh2 manual libssh2_channel_get_exit_signal(3)NAME
libssh2_channel_get_exit_signal - get the remote exit signal
SYNOPSIS
#include <libssh2.h>
int libssh2_channel_get_exit_signal(LIBSSH2_CHANNEL *channel, char **exitsignal, size_t *exitsignal_len, char **errmsg, size_t *errmsg_len,
char **langtag, size_t *langtag_len);
DESCRIPTION
channel - Closed channel stream to retrieve exit signal from.
exitsignal - If not NULL, is populated by reference with the exit signal (without leading "SIG"). Note that the string is stored in a newly
allocated buffer. If the remote program exited cleanly, the referenced string pointer will be set to NULL.
exitsignal_len - If not NULL, is populated by reference with the length of exitsignal.
errmsg - If not NULL, is populated by reference with the error message (if provided by remote server, if not it will be set to NULL). Note
that the string is stored in a newly allocated buffer.
errmsg_len - If not NULL, is populated by reference with the length of errmsg.
langtag - If not NULL, is populated by reference with the language tag (if provided by remote server, if not it will be set to NULL). Note
that the string is stored in a newly allocated buffer.
langtag_len - If not NULL, is populated by reference with the length of langtag.
RETURN VALUE
Numeric error code corresponding to the the Error Code constants.
libssh2 1.2.8 4 Oct 2010 libssh2_channel_get_exit_signal(3)
Check Out this Related Man Page
libssh2_channel_read_ex(3) libssh2 manual libssh2_channel_read_ex(3)NAME
libssh2_channel_read_ex - read data from a channel stream
SYNOPSIS
#include <libssh2.h>
ssize_t libssh2_channel_read_ex(LIBSSH2_CHANNEL *channel, int stream_id, char *buf, size_t buflen);
ssize_t libssh2_channel_read(LIBSSH2_CHANNEL *channel, char *buf, size_t buflen);
ssize_t libssh2_channel_read_stderr(LIBSSH2_CHANNEL *channel, char *buf, size_t buflen);
DESCRIPTION
Attempt to read data from an active channel stream. All channel streams have one standard I/O substream (stream_id == 0), and may have up
to 2^32 extended data streams as identified by the selected stream_id. The SSH2 protocol currently defines a stream ID of 1 to be the
stderr substream.
channel - active channel stream to read from.
stream_id - substream ID number (e.g. 0 or SSH_EXTENDED_DATA_STDERR)
buf - pointer to storage buffer to read data into
buflen - size of the buf storage
libssh2_channel_read(3) and libssh2_channel_read_stderr(3) are macros.
RETURN VALUE
Actual number of bytes read or negative on failure. It returns LIBSSH2_ERROR_EAGAIN when it would otherwise block. While LIB-
SSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
Note that a return value of zero (0) can in fact be a legitimate value and only signals that no payload data was read. It is not an error.
ERRORS
LIBSSH2_ERROR_SOCKET_SEND - Unable to send data on socket.
LIBSSH2_ERROR_CHANNEL_CLOSED - The channel has been closed.
SEE ALSO libssh2_poll_channel_read(3)libssh2 0.15 1 Jun 2007 libssh2_channel_read_ex(3)
I have a csv file, which is comma delimited. It has 300 fields, but not all are populated with data.
What I need to do is run a script that would look at each field and if it is populated then print the contents along with the field number, i.e. Joe Bloggs - 2 (Joe Bloggs is the data and 2 is... (4 Replies)
Reading this file. I want to read all 4 fields.
If 2 is populated with a p, I want to set $TYPEP to "Printers",
if not should be empty.
If 3 is populated with an r, I want to set $TYPER to "REQ Printers"
if not should be empty.
If 4 is populated with letter o, I want to set $TYPEO to... (12 Replies)
When and how is the variable $HOSTNAME populated ?
I am asking because I had a weird situation that just happened.
I have created backup scripts that do backups on different servers. Each servers has different folders to be backed up. So I had included a check on $HOSTNAME to find out which... (5 Replies)
Hi,
A script is running for multiple databases so data is also being populated for multiple DBs in a.txt file.
I need to rename this file once all the data is populated. Kindly suggest me How can I check once file is populated completely before renaming?
Thanks in advance. (3 Replies)
my file looks like this:
297 PC Closed 07/10/12 999000098 AMERICAN SOCIETY FOR HEALTHCAR 0.00 USD 1 NAI
i want to look line this:
297,PC,Closed,07/10/12,999000098,AMERICAN SOCIETY FOR HEALTHCAR,0.00,USD,1,NAI (4 Replies)