connection/write check