fix invalid-null-argument UBSAN error in TBufferTransports.cpp
fix invalid-null-argument UBSAN error in TBufferTransports.cpp

Summary:
Exposed by UBSAN:
{P59121568}

Add an if-statement to check if the second argument is not nullptr.

Reviewed By: yfeldblum

Differential Revision: D7099790

fbshipit-source-id: 4abf46e9fb165edcc5995780852fd29f02a46bc7

facebook/fbthrift,facebook/fbthrift,facebook/fbthrift,facebook/fbthrift,facebook/fbthrift,facebook/fbthrift,facebook/fbthrift,facebook/fbthrift,facebook/fbthrift