xrdp-ng: stream refactoring