Fix some minor warnings.
fix IndexOutOfBoundsException. ws request for write, but has no data, strang