Patch "pipe: fix off-by-one error when checking buffer limits" has been added to the 4.14-stable tree