--- obex_handler.c +++ obex_handler.c @@ -364,7 +364,7 @@ default: - printf(__FUNCTION__ "() Skipped header %02x\n", hi); + printf("%s() Skipped header %02x\n", __FUNCTION__, hi); } } @@ -499,12 +499,12 @@ - printf(__FUNCTION__ "()\n"); + printf("%s()\n", __FUNCTION__); while(OBEX_ObjectGetNextHeader(handle, object, &hi, &hv, &hlen)){ switch(hi) { case OBEX_HDR_NAME: - printf(__FUNCTION__ "() Found name\n"); + printf("%s() Found name\n", __FUNCTION__); if( hlen/2 < sizeof(NameBuf) ){ OBEX_UnicodeToChar(NameBuf, hv.bs, hlen); @@ -513,7 +513,7 @@ break; case OBEX_HDR_TYPE: - printf(__FUNCTION__ "() HEADER_TYPE = '%s' #%d \n", hv.bs, hlen); + printf("%s() HEADER_TYPE = '%s' #%d \n", __FUNCTION__, hv.bs, hlen); if( hlen < sizeof(TypeBuf) ){ strcpy(TypeBuf,hv.bs); @@ -522,17 +522,17 @@ break; case 0xcb: - printf(__FUNCTION__ "()CONNECTION_ID = %#x (%d length)\n", hv.bq4,hlen); + printf("%s()CONNECTION_ID = %#x (%d length)\n", __FUNCTION__, hv.bq4,hlen); break; case 0x71: - printf(__FUNCTION__ "()IMAGE_DESCRIPTION = ? (%d length)\n",hlen); + printf("%s()IMAGE_DESCRIPTION = ? (%d length)\n", __FUNCTION__, hlen); dump_hex((void *)hv.bs,hlen); break; default: - printf(__FUNCTION__ "() Skipped header %02x\n", hi); + printf("%s() Skipped header %02x\n", __FUNCTION__, hi); } } @@ -556,9 +556,9 @@ // We won'tanswer any other get's. // if(GotName){ - printf(__FUNCTION__ "() Got a request for %s\n", NameBuf); + printf("%s() Got a request for %s\n", __FUNCTION__, NameBuf); }else{ - printf(__FUNCTION__ "() Got a GET without a name-header!\n"); + printf("%s() Got a GET without a name-header!\n", __FUNCTION__); } OBEX_ObjectSetRsp(object, OBEX_RSP_NOT_FOUND, OBEX_RSP_NOT_FOUND); @@ -618,7 +618,7 @@ break; default: - printf(__FUNCTION__ "() Denied %02x request\n", cmd); + printf("%s() Denied %02x request\n", __FUNCTION__, cmd); OBEX_ObjectSetRsp(object, OBEX_RSP_NOT_IMPLEMENTED, OBEX_RSP_NOT_IMPLEMENTED); break;