diff --git a/common/os_calls.c b/common/os_calls.c index dbef8da6..8ce5c25a 100644 --- a/common/os_calls.c +++ b/common/os_calls.c @@ -399,7 +399,7 @@ g_tcp_set_keepalive(int sck) /*****************************************************************************/ /* returns a newly created socket or -1 on error */ -/* in win32 a socket is an unsigned int, in linux, its an int */ +/* in win32 a socket is an unsigned int, in linux, it's an int */ int APP_CC g_tcp_socket(void) { diff --git a/docs/man/xrdp.ini.5 b/docs/man/xrdp.ini.5 index 8e6969cd..6f727971 100644 --- a/docs/man/xrdp.ini.5 +++ b/docs/man/xrdp.ini.5 @@ -158,7 +158,7 @@ This option sets the logging level for syslog. It can have the same values of \f .SH "CHANNELS" The Remote Desktop Protocol supports several channels, which are used to transfer additional data like sound, clipboard data and others. Channel names not listed here will be blocked by \fBxrdp\fP. -Not all channels are supported in all cases, so setting a value to \fItrue\fP is a pre-requisite, but does not force it's use. +Not all channels are supported in all cases, so setting a value to \fItrue\fP is a pre-requisite, but does not force its use. .br Channels can also be enabled or disabled on a per connection basis by prefixing each setting with \fBchannel.\fP in the channel section. diff --git a/faq-general.txt b/faq-general.txt index e63804cb..53dab380 100644 --- a/faq-general.txt +++ b/faq-general.txt @@ -2,17 +2,17 @@ General FAQ Q. What is RDP? -A. RDP stands for Remote Desktop Protocol. Its the protocol used by Windows +A. RDP stands for Remote Desktop Protocol. It's the protocol used by Windows terminal servers to talk to the terminal server clients. Q. What is xrdp? -A. xrdp, usually spell lower case, is as open source implementation of the RDP - protocol. +A. xrdp, usually spelled in lower case, is as open source implementation of the + RDP protocol. -Q. I can't get it to compile in Ubuntu. What can I do? +Q. I can't get xrdp to compile in Ubuntu. What can I do? A. See faq-compile.txt. diff --git a/libxrdp/libxrdp.c b/libxrdp/libxrdp.c index 0b92668a..daa7ca75 100644 --- a/libxrdp/libxrdp.c +++ b/libxrdp/libxrdp.c @@ -485,12 +485,12 @@ libxrdp_send_bitmap(struct xrdp_session *session, int width, int height, if (j > 32768) { - g_writeln("error, decompressed size too big, its %d", j); + g_writeln("error, decompressed size too big: %d bytes", j); } if (bufsize > 8192) { - g_writeln("error, compressed size too big, its %d", bufsize); + g_writeln("error, compressed size too big: %d bytes", bufsize); } s->p = s->end; @@ -504,7 +504,7 @@ libxrdp_send_bitmap(struct xrdp_session *session, int width, int height, if (total_bufsize > 8192) { - g_writeln("error, total compressed size too big, its %d", + g_writeln("error, total compressed size too big: %d bytes", total_bufsize); } } diff --git a/libxrdp/xrdp_mcs.c b/libxrdp/xrdp_mcs.c index 6f04e719..8ed821e9 100644 --- a/libxrdp/xrdp_mcs.c +++ b/libxrdp/xrdp_mcs.c @@ -1023,7 +1023,7 @@ xrdp_mcs_send(struct xrdp_mcs *self, struct stream *s, int chan) if (len > 8192 * 2) { - g_writeln("error in xrdp_mcs_send, size too big, its %d", len); + g_writeln("error in xrdp_mcs_send, size too big: %d bytes", len); } //if (len > max_len) diff --git a/libxrdp/xrdp_orders.c b/libxrdp/xrdp_orders.c index 697d2a5a..18a5ad38 100644 --- a/libxrdp/xrdp_orders.c +++ b/libxrdp/xrdp_orders.c @@ -236,7 +236,7 @@ xrdp_orders_check(struct xrdp_orders *self, int max_size) size = (int)(self->out_s->p - self->order_count_ptr); if (size < 0) { - g_writeln("error in xrdp_orders_check, size too small, its %d", size); + g_writeln("error in xrdp_orders_check, size too small: %d bytes", size); return 1; } if (size > max_packet_size) @@ -244,7 +244,7 @@ xrdp_orders_check(struct xrdp_orders *self, int max_size) /* this suggests someone calls this function without passing the correct max_size so we end up putting more into the buffer than we indicate we can */ - g_writeln("error in xrdp_orders_check, size too big, its %d", size); + g_writeln("error in xrdp_orders_check, size too big: %d bytes", size); /* We where getting called with size already greater than max_packet_size Which I suspect was because the sending of text did not include @@ -507,7 +507,7 @@ xrdp_orders_rect(struct xrdp_orders *self, int x, int y, int cx, int cy, if (rect != 0) { - /* if clip is present, still check if its needed */ + /* if clip is present, still check if it's needed */ if (x < rect->left || y < rect->top || x + cx > rect->right || y + cy > rect->bottom) { @@ -678,7 +678,7 @@ xrdp_orders_screen_blt(struct xrdp_orders *self, int x, int y, if (rect != 0) { - /* if clip is present, still check if its needed */ + /* if clip is present, still check if it's needed */ if (x < rect->left || y < rect->top || x + cx > rect->right || y + cy > rect->bottom) { @@ -870,7 +870,7 @@ xrdp_orders_pat_blt(struct xrdp_orders *self, int x, int y, if (rect != 0) { - /* if clip is present, still check if its needed */ + /* if clip is present, still check if it's needed */ if (x < rect->left || y < rect->top || x + cx > rect->right || y + cy > rect->bottom) { @@ -1087,7 +1087,7 @@ xrdp_orders_dest_blt(struct xrdp_orders *self, int x, int y, if (rect != 0) { - /* if clip is present, still check if its needed */ + /* if clip is present, still check if it's needed */ if (x < rect->left || y < rect->top || x + cx > rect->right || y + cy > rect->bottom) { @@ -1258,7 +1258,7 @@ xrdp_orders_line(struct xrdp_orders *self, int mix_mode, if (rect != 0) { - /* if clip is present, still check if its needed */ + /* if clip is present, still check if it's needed */ if (MIN(endx, startx) < rect->left || MIN(endy, starty) < rect->top || MAX(endx, startx) >= rect->right || @@ -1460,7 +1460,7 @@ xrdp_orders_mem_blt(struct xrdp_orders *self, int cache_id, if (rect != 0) { - /* if clip is present, still check if its needed */ + /* if clip is present, still check if it's needed */ if (x < rect->left || y < rect->top || x + cx > rect->right || y + cy > rect->bottom) { @@ -1667,7 +1667,7 @@ xrdp_orders_composite_blt(struct xrdp_orders* self, int srcidx, int srcformat, self->orders_state.last_order = RDP_ORDER_COMPOSITE; if (rect != 0) { - /* if clip is present, still check if its needed */ + /* if clip is present, still check if it's needed */ if (dstx < rect->left || dsty < rect->top || dstx + width > rect->right || dsty + height > rect->bottom) { @@ -1999,7 +1999,7 @@ xrdp_orders_text(struct xrdp_orders *self, if (rect != 0) { - /* if clip is present, still check if its needed */ + /* if clip is present, still check if it's needed */ if ((box_right - box_left > 1 && (box_left < rect->left || box_top < rect->top || diff --git a/libxrdp/xrdp_sec.c b/libxrdp/xrdp_sec.c index af0cedf2..a31190ca 100644 --- a/libxrdp/xrdp_sec.c +++ b/libxrdp/xrdp_sec.c @@ -2101,7 +2101,7 @@ xrdp_sec_in_mcs_data(struct xrdp_sec *self) client_info = &(self->rdp_layer->client_info); s = &(self->client_mcs_data); - /* get hostname, its unicode */ + /* get hostname, it's unicode */ s->p = s->data; if (!s_check_rem(s, 47)) { diff --git a/prog_std.txt b/prog_std.txt index 671172f2..761006a5 100644 --- a/prog_std.txt +++ b/prog_std.txt @@ -1,7 +1,8 @@ This is an attempt to explain my odd programming standard used for this project. -Not to defend any of these but its my default standard and make it easy -for me to read. +Not to defend any of these but it's my default standard and it makes it easy +for me to read code. + Some files break these rules, they will be updated eventually. try to make any file compile with c++ compilers @@ -30,7 +31,7 @@ don't use tabs, use spaces no line should exceed 80 chars -always use {} in if and while, even if its only one line +always use {} in if and while, even if it's only one line while (p != 0) { p = p->next; diff --git a/sesman/sessvc/sessvc.c b/sesman/sessvc/sessvc.c index dce88d17..3fb80a60 100644 --- a/sesman/sessvc/sessvc.c +++ b/sesman/sessvc/sessvc.c @@ -49,7 +49,7 @@ nil_signal_handler(int sig) } /******************************************************************************/ -/* chansrv can exit at any time without cleaning up, its an xlib app */ +/* chansrv can exit at any time without cleaning up, it's an xlib app */ int APP_CC chansrv_cleanup(int pid) { diff --git a/tests/gtcp_proxy/gtcp.c b/tests/gtcp_proxy/gtcp.c index 4b218a3c..504138bf 100644 --- a/tests/gtcp_proxy/gtcp.c +++ b/tests/gtcp_proxy/gtcp.c @@ -33,7 +33,7 @@ int tcp_socket_create(void) unsigned int option_len; #endif - /* in win32 a socket is an unsigned int, in linux, its an int */ + /* in win32 a socket is an unsigned int, in linux, it's an int */ if ((rv = (int) socket(PF_INET, SOCK_STREAM, 0)) < 0) return -1; @@ -193,7 +193,7 @@ int tcp_socket(void) unsigned int option_len; #endif - /* in win32 a socket is an unsigned int, in linux, its an int */ + /* in win32 a socket is an unsigned int, in linux, it's an int */ if ((rv = (int) socket(PF_INET, SOCK_STREAM, 0)) < 0) return -1; diff --git a/xorg/X11R7.6/rdp/rdpinput.c b/xorg/X11R7.6/rdp/rdpinput.c index f221ae34..4c976417 100644 --- a/xorg/X11R7.6/rdp/rdpinput.c +++ b/xorg/X11R7.6/rdp/rdpinput.c @@ -27,7 +27,7 @@ keyboard and mouse stuff num lock */ /* this should be fixed in rdesktop */ /* g_pause_spe flag for special control sent by ms client before scan code - 69 is sent to tell that its pause, not num lock. both pause and num + 69 is sent to tell that it's pause, not num lock. both pause and num lock use scan code 69 */ /* tab notes */ diff --git a/xrdp/xrdp.c b/xrdp/xrdp.c index 88743cc6..740b0e1c 100644 --- a/xrdp/xrdp.c +++ b/xrdp/xrdp.c @@ -443,8 +443,7 @@ main(int argc, char **argv) if (fd == -1) { - g_writeln("problem opening to xrdp.pid [%s]", pid_file); - g_writeln("maybe its not running"); + g_writeln("cannot open %s, maybe xrdp is not running", pid_file); } else { diff --git a/xrdp/xrdp_types.h b/xrdp/xrdp_types.h index 4590d7a8..d6c7ccb1 100644 --- a/xrdp/xrdp_types.h +++ b/xrdp/xrdp_types.h @@ -216,7 +216,7 @@ struct xrdp_brush_item { int stamp; /* expand this to a structure to handle more complicated brushes - for now its 8x8 1bpp brushes only */ + for now it's 8x8 1bpp brushes only */ char pattern[8]; }; diff --git a/xrdp/xrdp_wm.c b/xrdp/xrdp_wm.c index 3b223902..ca466197 100644 --- a/xrdp/xrdp_wm.c +++ b/xrdp/xrdp_wm.c @@ -1725,8 +1725,8 @@ callback(long id, int msg, long param1, long param2, long param3, long param4) rv = xrdp_wm_process_input_mousex(wm, param3, param1, param2); break; case 0x4444: /* invalidate, this is not from RDP_DATA_PDU_INPUT */ - /* like the rest, its from RDP_PDU_DATA with code 33 */ - /* its the rdp client asking for a screen update */ + /* like the rest, it's from RDP_PDU_DATA with code 33 */ + /* it's the rdp client asking for a screen update */ MAKERECT(rect, param1, param2, param3, param4); rv = xrdp_bitmap_invalidate(wm->screen, &rect); break; diff --git a/xrdp/xrdpwin.c b/xrdp/xrdpwin.c index 224efc0c..25ca6048 100644 --- a/xrdp/xrdpwin.c +++ b/xrdp/xrdpwin.c @@ -466,8 +466,8 @@ main(int argc, char **argv) if (fd == -1) { - g_writeln("problem opening to xrdp.pid"); - g_writeln("maybe its not running"); + g_writeln("cannot open %s, maybe xrdp is not running", + pid_file); } else {