ref: b298429804d255c629dfc15f59081f2b05b513a8
parent: e2f0077935e5f588f555061feb99ec651f80b45b
author: cinap_lenrek <cinap_lenrek@centraldogma>
date: Fri Sep 2 23:26:44 EDT 2011
ptp: fix fallback case
--- a/sys/src/cmd/nusb/ptp/ptp.c
+++ b/sys/src/cmd/nusb/ptp/ptp.c
@@ -826,7 +826,7 @@
respond(r, nil);
return;
}
- while(nod->data == nil){
+ if(nod->data == nil){
int offset, count, pos;
offset = r->ifcall.offset;
@@ -857,8 +857,8 @@
/* no break */
case Qthumb:
if(nod->data == nil){
- p = nil;
np = 0;
+ p = nil;
if(ptprpc(r, TYPE(path)==Qthumb ? GetThumb : GetObject,
1|DataRecv, nod->handle, &p, &np) < 0){
free(p);