bluetooth/btstack/linkmgr/ACLSAP.cpp
branchRCL_3
changeset 17 32ba20339036
parent 16 9f17f914e828
child 18 1f10b9300be6
equal deleted inserted replaced
16:9f17f914e828 17:32ba20339036
  1087 		{
  1087 		{
  1088 		// New physical link connection request
  1088 		// New physical link connection request
  1089 		CPhysicalLink* physicalLink = &iLinksMan.NewPhysicalLinkL(iRemoteDev);
  1089 		CPhysicalLink* physicalLink = &iLinksMan.NewPhysicalLinkL(iRemoteDev);
  1090 		// physicalLink is owned by the physical links manager.
  1090 		// physicalLink is owned by the physical links manager.
  1091 		User::LeaveIfError(BindLink(EACLLink, *physicalLink));
  1091 		User::LeaveIfError(BindLink(EACLLink, *physicalLink));
  1092 		TInt err = iPhysicalLink->Connect();
  1092 		iPhysicalLink->Connect();
  1093 		if(err != KErrNone)
       
  1094 			{
       
  1095 			// If we failed to connect then we should roll back the attachment
       
  1096 			ClearPhysicalLink();
       
  1097 			User::Leave(err);
       
  1098 			}
       
  1099 		}
  1093 		}
  1100 	}
  1094 	}
  1101 
  1095 
  1102 TInt CACLLink::SetLocalName(TSockAddr& aAddr)
  1096 TInt CACLLink::SetLocalName(TSockAddr& aAddr)
  1103 	{
  1097 	{