diff options
Diffstat (limited to 'media/mtp/MtpDataPacket.cpp')
| -rw-r--r-- | media/mtp/MtpDataPacket.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/media/mtp/MtpDataPacket.cpp b/media/mtp/MtpDataPacket.cpp index d12425a..a7e975c 100644 --- a/media/mtp/MtpDataPacket.cpp +++ b/media/mtp/MtpDataPacket.cpp @@ -14,6 +14,8 @@ * limitations under the License. */ +#define LOG_TAG "MtpDataPacket" + #include <stdio.h> #include <sys/types.h> #include <fcntl.h> @@ -312,15 +314,12 @@ void MtpDataPacket::putString(const char* s) int MtpDataPacket::read(int fd) { // first read the header int ret = ::read(fd, mBuffer, MTP_CONTAINER_HEADER_SIZE); -printf("MtpDataPacket::read 1 returned %d\n", ret); if (ret != MTP_CONTAINER_HEADER_SIZE) return -1; // then the following data int total = MtpPacket::getUInt32(MTP_CONTAINER_LENGTH_OFFSET); int remaining = total - MTP_CONTAINER_HEADER_SIZE; -printf("total: %d, remaining: %d\n", total, remaining); ret = ::read(fd, &mBuffer[0] + MTP_CONTAINER_HEADER_SIZE, remaining); -printf("MtpDataPacket::read 2 returned %d\n", ret); if (ret != remaining) return -1; |
