messagingappbase/obexmtms/obexmtm/obexutil/source/ObexSdpUtils.cpp
changeset 23 238255e8b033
parent 0 72b543305e3a
child 47 5b14749788d7
child 60 7fdbb852d323
equal deleted inserted replaced
5:4697dfb2d7ad 23:238255e8b033
   183 		// if we have started a SDP agent
   183 		// if we have started a SDP agent
   184    		{
   184    		{
   185 			delete iSdpAgent;	
   185 			delete iSdpAgent;	
   186 		
   186 		
   187 		}
   187 		}
   188 
   188 	
   189 	iAttributeArray->ResetAndDestroy();
   189 	if(iAttributeArray)
       
   190 	    iAttributeArray->ResetAndDestroy();
   190 	delete iAttributeArray;
   191 	delete iAttributeArray;
   191 	}
   192 	}
   192 
   193 
   193 
   194 
   194 EXPORT_C void CObexSdpUtils::RemoteBtObexQueryL(TBTDevAddr aBtDevAddr)
   195 EXPORT_C void CObexSdpUtils::RemoteBtObexQueryL(TBTDevAddr aBtDevAddr)
   303 		// See if we should continue looking at the attributes for this record
   304 		// See if we should continue looking at the attributes for this record
   304 		if (iNotThisSdpRecord //there was a problem with attribute UUIDs and Uints
   305 		if (iNotThisSdpRecord //there was a problem with attribute UUIDs and Uints
   305 		    || (iExpectedType==EAnythingUntilNextExpectedValue) //we should have got whatever we expected next!
   306 		    || (iExpectedType==EAnythingUntilNextExpectedValue) //we should have got whatever we expected next!
   306 		    || (iExpectedType==EUint) //we should always get the Uint we are looking for
   307 		    || (iExpectedType==EUint) //we should always get the Uint we are looking for
   307 			|| (iExpectedType==EUUID) //we should always get the UUID we are looking for 
   308 			|| (iExpectedType==EUUID) //we should always get the UUID we are looking for 
   308 			|| (aError)) //an error has occured, note that not finding an attribute does NOT result in KErrNotFound
   309 			|| (aError)) //an error has occurred, note that not finding an attribute does NOT result in KErrNotFound
   309 			{
   310 			{
   310 			// following is an exception to the rules above...
   311 			// following is an exception to the rules above...
   311 			if (iCurrentAttributeId==KBluetoothProfileDescriptorListAttributeId) //it OK to not find what we expect in for attribute because attribute is not mandatory
   312 			if (iCurrentAttributeId==KBluetoothProfileDescriptorListAttributeId) //it OK to not find what we expect in for attribute because attribute is not mandatory
   312 				{
   313 				{
   313 				// therefore everything is OK with the record so far - Request the next attribute
   314 				// therefore everything is OK with the record so far - Request the next attribute
   381 		}
   382 		}
   382 	else if (iExpectingSpecific)
   383 	else if (iExpectingSpecific)
   383 		{
   384 		{
   384 		if (aUUID != TUUID(iExpectedValue))
   385 		if (aUUID != TUUID(iExpectedValue))
   385 			{
   386 			{
   386 			// Havn't got what we expected!
   387 			// Haven't got what we expected!
   387 			iNotThisSdpRecord = ETrue;
   388 			iNotThisSdpRecord = ETrue;
   388 			}
   389 			}
   389 		else if (aUUID==TUUID(KObexObjectPushUUIDValue) && iCurrentAttributeId==KBluetoothProfileDescriptorListAttributeId)
   390 		else if (aUUID==TUUID(KObexObjectPushUUIDValue) && iCurrentAttributeId==KBluetoothProfileDescriptorListAttributeId)
   390 			{
   391 			{
   391 			// remote device complies fully with obex object push profile
   392 			// Remote device complies fully with obex object push profile
   392 			iFullComplianceWithObexObjectPush = ETrue;;
   393 			iFullComplianceWithObexObjectPush = ETrue;;
   393 			}
   394 			}
   394 		}
   395 		}
   395 	else
   396 	else
   396 		{
   397 		{
   442 		}
   443 		}
   443 	else if (iExpectingSpecific)
   444 	else if (iExpectingSpecific)
   444 		{
   445 		{
   445 		if (uint != iExpectedValue)
   446 		if (uint != iExpectedValue)
   446 			{
   447 			{
   447 			// Havn't got what we expected!
   448 			// haven't got what we expected!
   448 			iNotThisSdpRecord = ETrue;
   449 			iNotThisSdpRecord = ETrue;
   449 			}
   450 			}
   450 		}
   451 		}
   451 	else
   452 	else
   452 		{
   453 		{