Return empty body instead -ENOENT when phonebook is empty
PATCH 1/2 Return empty body instead -ENOENT when phonebook is empty
Previously, when doing pull of empty phonebook, NOT FOUND error was returned. Now returning empty body - this change is needed to pass PTS testcase TC_PSE_PDF_BV_05_I (this testcase is optional).
PBAP spec says, that error NOT_FOUND should be returned when phonebook object could not be found - very strict clients may think that phonebook does not exist (and in scenario described above phonebook exists but its content is empty).
--- plugins/pbap.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
plugins/pbap.c +1 -1
@@ -301,7 +301,7 @@ static void query_result(const char *buffer, size_t bufsize, int vcards, pbap->obj->lastpart = lastpart; -if (vcards <=0 ) { +if (vcards <0 ) {obex_object_set_io_flags (pbap->obj,G_IO_ERR , -ENOENT );return ; }
Signature · 1 line
1.6.3.3
Hi Rafal,
Quoted 11 lines · Rafal Michalski
Previously, when doing pull of empty phonebook, NOT FOUND error was returned. Now returning empty body - this change is needed to pass PTS testcase
TC_PSE_PDF_BV_05_I(this testcase is optional).PBAP spec says, that error
NOT_FOUNDshould be returned when phonebook object could not be found - very strict clients may think that phonebook does not exist (and in scenario described above phonebook exists but its content is empty).--- plugins/pbap.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
Both patches have been applied. Thanks.
Johan