Changed function names.
Removed unneeded move.
Adjustments.
New functions.
Adjustments.
Use binary mode in file I/O (for non-POSIX systems).