From 54eea0c0974e10f04a4339947e8375653a1b4cb1 Mon Sep 17 00:00:00 2001 From: Rakesh M K Date: Tue, 25 Nov 2014 17:08:28 +0530 Subject: [PATCH] src/profile: Add HSP default record for external profiles --- src/profile.c | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) diff --git a/src/profile.c b/src/profile.c index 252063bdc..6e272c429 100644 --- a/src/profile.c +++ b/src/profile.c @@ -153,6 +153,44 @@ \ " +#define HSP_AG_RECORD \ + " \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + \ + " + #define SPP_RECORD \ " \ \ @@ -1704,6 +1742,13 @@ static char *get_hfp_ag_record(struct ext_profile *ext, struct ext_io *l2cap, ext->name, ext->features); } +static char *get_hsp_ag_record(struct ext_profile *ext, struct ext_io *l2cap, + struct ext_io *rfcomm) +{ + return g_strdup_printf(HSP_AG_RECORD, rfcomm->chan, ext->version, + ext->name); +} + static char *get_spp_record(struct ext_profile *ext, struct ext_io *l2cap, struct ext_io *rfcomm) { @@ -1913,6 +1958,8 @@ static struct default_settings { .channel = HSP_AG_DEFAULT_CHANNEL, .authorize = true, .auto_connect = true, + .get_record = get_hsp_ag_record, + .version = 0x0102, }, { .uuid = OBEX_OPP_UUID, .name = "Object Push", -- 2.47.3