Fix the optional file to send over transport handling.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@39227 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Philippe Houdoin
2010-10-31 10:44:56 +00:00
parent 27de01cb63
commit 1c9f7a4117
+3 -3
View File
@@ -56,7 +56,7 @@ int main (int argc, char *argv[])
argc -= optind;
argv += optind;
if (argc != 1) {
if (argc < 1) {
usage(argc, argv);
return -1;
}
@@ -149,8 +149,8 @@ int main (int argc, char *argv[])
printf("failed!\n");
if (argc > 2) {
BFile data(argv[2], B_READ_ONLY);
if (argc > 1) {
BFile data(argv[1], B_READ_ONLY);
if (data.InitCheck() == B_OK) {
uint8 buffer[B_PAGE_SIZE];
ssize_t total = 0;