code style: change tabs to spaces

This commit is contained in:
Marek Marczykowski-Górecki 2013-12-27 05:31:11 +01:00
parent 6e47f12118
commit 0ba692c85a
2 changed files with 744 additions and 747 deletions

View File

@ -65,8 +65,8 @@ static int local_stdin_fd, local_stdout_fd;
void do_exit(int code)
{
int status;
// sever communication lines; wait for child, if any
// so that qrexec-daemon can count (recursively) spawned processes correctly
// sever communication lines; wait for child, if any
// so that qrexec-daemon can count (recursively) spawned processes correctly
close(local_stdin_fd);
close(local_stdout_fd);
waitpid(-1, &status, 0);

View File

@ -48,9 +48,9 @@ struct _client {
};
/*
The "clients" array is indexed by client's fd.
Thus its size must be equal MAX_FDS; defining MAX_CLIENTS for clarity.
*/
The "clients" array is indexed by client's fd.
Thus its size must be equal MAX_FDS; defining MAX_CLIENTS for clarity.
*/
#define MAX_CLIENTS MAX_FDS
struct _client clients[MAX_CLIENTS]; // data on all qrexec_client connections
@ -371,10 +371,10 @@ void handle_message_from_client(int fd)
}
/*
Called when there is buffered data for this client, and select() reports
that client's pipe is writable; so we should be able to flush some
buffered data.
*/
* Called when there is buffered data for this client, and select() reports
* that client's pipe is writable; so we should be able to flush some
* buffered data.
*/
void write_buffered_data_to_client(int client_id)
{
switch (flush_client_data
@ -401,9 +401,9 @@ void write_buffered_data_to_client(int client_id)
}
/*
The header (hdr argument) is already built. Just read the raw data from
the packet, and pass it along with the header to the client.
*/
* The header (hdr argument) is already built. Just read the raw data from
* the packet, and pass it along with the header to the client.
*/
void get_packet_data_from_agent_and_pass_to_client(int client_id, struct client_header
*hdr)
{
@ -440,10 +440,10 @@ void get_packet_data_from_agent_and_pass_to_client(int client_id, struct client_
}
/*
The signal handler executes asynchronously; therefore all it should do is
to set a flag "signal has arrived", and let the main even loop react to this
flag in appropriate moment.
*/
* The signal handler executes asynchronously; therefore all it should do is
* to set a flag "signal has arrived", and let the main even loop react to this
* flag in appropriate moment.
*/
int child_exited;
@ -503,8 +503,8 @@ void sanitize_name(char * untrusted_s_signed)
#define ENSURE_NULL_TERMINATED(x) x[sizeof(x)-1] = 0
/*
Called when agent sends a message asking to execute a predefined command.
*/
* Called when agent sends a message asking to execute a predefined command.
*/
void handle_execute_predefined_command(void)
{
@ -595,9 +595,6 @@ void handle_message_from_agent(void)
s_hdr = untrusted_s_hdr;
/* sanitize end */
// fprintf(stderr, "got %x %x %x\n", s_hdr.type, s_hdr.client_id,
// s_hdr.len);
if (s_hdr.type == MSG_AGENT_TO_SERVER_TRIGGER_CONNECT_EXISTING) {
handle_execute_predefined_command();
return;
@ -643,11 +640,11 @@ void handle_message_from_agent(void)
}
/*
Scan the "clients" table, add ones we want to read from (because the other
end has not send MSG_XOFF on them) to read_fdset, add ones we want to write
to (because its pipe is full) to write_fdset. Return the highest used file
descriptor number, needed for the first select() parameter.
*/
* Scan the "clients" table, add ones we want to read from (because the other
* end has not send MSG_XOFF on them) to read_fdset, add ones we want to write
* to (because its pipe is full) to write_fdset. Return the highest used file
* descriptor number, needed for the first select() parameter.
*/
int fill_fdsets_for_select(fd_set * read_fdset, fd_set * write_fdset)
{
int i;