app_server: avoids referencing a temporary IntRect instance.

* GCC lets us use a const reference to a temporary, but using it after it disappeared
  is incorrect.
* reverts hrev45576 as this patch seems more correct.
write_overlay: fixed three warnings, I hope correctly.

* warnings about comparison between signed and unsigned integer expressions.
nfs4: fixed two warnings.

* warnings about comparison between signed and unsigned integer expressions.
* the use of max_c() was superflous anyway as the result is only used for a comparison
with the left value.
vfs: fixed two warnings.

* warnings about comparison between signed and unsigned integer expressions.
keymap: use uchar instead of char to avoid narrowing conversion warnings.
kernel: use uint64 instead of int64 to avoid narrowing conversion warnings.

* gdb_register is used only in arch_debug.cpp
attribute_overlay: fixed a warning.

* warning about comparison between signed and unsigned integer expressions.
Installer: fixed two warnings.

* warnings about comparison between signed and unsigned integer expressions.
* also use std::min() instead of min_c()
SoundRecorder: fixed two warnings.

* warnings about comparison between signed and unsigned integer expressions.
* also use std::min() instead of min_c()
Terminal: use unsigned short instead of int to avoid a narrowing conversion warning.

* unsigned short is the type used in the struct winsize.
bsnow: use uchar instead of char to avoid narrowing conversion warnings.