From: Johan H. <joh...@no...> - 2007-01-24 19:24:45
|
Hi Bea, On Wed, Jan 24, 2007, Bea Lam wrote: > I've looked at it again and I've realised it's possible to recognise > the Delete and Create commands without a patch. To work around it, the > user just has to keep track of whether the OBEX_EV_STREAMAVAIL event > is received or not in order to determine whether the command is a > Put-Delete, since this event is not received if no Body nor > End-of-Body headers are received while streaming a Put. > > To recognise a Create command, the user needs to recognise Delete > commands; i.e. if it's a Put operation that's not a Delete, and the > body length is zero, it must be a Create. So with this workaround, the > Create command cannot be recognised without also recognising the > Delete command. It seems that even if detecting these cases is currently possible, a simpler (and more intuitive) way to do it would be a good thing to have. A "get flags" function would probably do the trick. Is the patch you sent still your latest proposal or do you have an updated version? (I don't really have any strong opinion about whether it should be OBEX_ObjectGetPutFlags or a generic OBEX_ObjectGetRequestFlags). Johan |