diff options
| author | James Cook <james@lindenlab.com> | 2010-02-03 14:13:56 -0800 | 
|---|---|---|
| committer | James Cook <james@lindenlab.com> | 2010-02-03 14:13:56 -0800 | 
| commit | 88350edbcbec615f3b15fc82bd5ce4005621ac6f (patch) | |
| tree | c244f41159cf32f3e03c6c311e1453bbd383bad5 /indra/llmessage | |
| parent | d489216b6ef41f0d22f3a9062ba6daacc67bc038 (diff) | |
| parent | 0bee31de32cb5999e7ec06d74f55d34ce0ac052b (diff) | |
merge
Diffstat (limited to 'indra/llmessage')
| -rw-r--r-- | indra/llmessage/llares.cpp | 15 | ||||
| -rw-r--r-- | indra/llmessage/llcachename.cpp | 4 | ||||
| -rw-r--r-- | indra/llmessage/llhttpassetstorage.cpp | 3 | ||||
| -rw-r--r-- | indra/llmessage/llhttpnode.h | 2 | ||||
| -rw-r--r-- | indra/llmessage/llinstantmessage.cpp | 2 | ||||
| -rw-r--r-- | indra/llmessage/lliohttpserver.cpp | 11 | ||||
| -rw-r--r-- | indra/llmessage/llmessagetemplate.h | 4 | ||||
| -rw-r--r-- | indra/llmessage/llmessagetemplateparser.cpp | 4 | ||||
| -rw-r--r-- | indra/llmessage/llnamevalue.cpp | 1 | ||||
| -rw-r--r-- | indra/llmessage/llpacketbuffer.cpp | 5 | ||||
| -rw-r--r-- | indra/llmessage/lltemplatemessagebuilder.cpp | 8 | ||||
| -rw-r--r-- | indra/llmessage/lltransfermanager.cpp | 2 | ||||
| -rw-r--r-- | indra/llmessage/lltransfersourceasset.cpp | 5 | ||||
| -rw-r--r-- | indra/llmessage/lltransfertargetfile.h | 7 | ||||
| -rw-r--r-- | indra/llmessage/lltransfertargetvfile.h | 1 | ||||
| -rw-r--r-- | indra/llmessage/llxfer.cpp | 1 | ||||
| -rw-r--r-- | indra/llmessage/message.cpp | 4 | ||||
| -rw-r--r-- | indra/llmessage/partsyspacket.cpp | 2 | 
18 files changed, 62 insertions, 19 deletions
| diff --git a/indra/llmessage/llares.cpp b/indra/llmessage/llares.cpp index 104629c157..00e77d20e9 100644 --- a/indra/llmessage/llares.cpp +++ b/indra/llmessage/llares.cpp @@ -175,7 +175,8 @@ void LLAres::rewriteURI(const std::string &uri, UriRewriteResponder *resp)  LLQueryResponder::LLQueryResponder()  	: LLAres::QueryResponder(), -	  mResult(ARES_ENODATA) +	  mResult(ARES_ENODATA), +	  mType(RES_INVALID)  {  } @@ -641,8 +642,10 @@ LLPtrRecord::LLPtrRecord(const std::string &name, unsigned ttl)  }  LLAddrRecord::LLAddrRecord(LLResType type, const std::string &name, -						   unsigned ttl) -	: LLDnsRecord(type, name, ttl) +			   unsigned ttl) +	: LLDnsRecord(type, name, ttl), + +	  mSize(0)  {  } @@ -701,7 +704,11 @@ bail:  }  LLSrvRecord::LLSrvRecord(const std::string &name, unsigned ttl) -	: LLHostRecord(RES_SRV, name, ttl) +	: LLHostRecord(RES_SRV, name, ttl), + +	  mPriority(0), +	  mWeight(0), +	  mPort(0)  {  } diff --git a/indra/llmessage/llcachename.cpp b/indra/llmessage/llcachename.cpp index e1e5f5bc02..e6233ecf97 100644 --- a/indra/llmessage/llcachename.cpp +++ b/indra/llmessage/llcachename.cpp @@ -81,6 +81,8 @@ public:  };  LLCacheNameEntry::LLCacheNameEntry() +	: mIsGroup(false), +	  mCreateTime(0)  {  } @@ -125,7 +127,7 @@ private:  };  ReplySender::ReplySender(LLMessageSystem* msg) -	: mMsg(msg), mPending(false) +	: mMsg(msg), mPending(false), mCurrIsGroup(false)  { }  ReplySender::~ReplySender() diff --git a/indra/llmessage/llhttpassetstorage.cpp b/indra/llmessage/llhttpassetstorage.cpp index 49dbdbd56d..1980735bbb 100644 --- a/indra/llmessage/llhttpassetstorage.cpp +++ b/indra/llmessage/llhttpassetstorage.cpp @@ -126,8 +126,9 @@ LLHTTPAssetRequest::LLHTTPAssetRequest(LLHTTPAssetStorage *asp,  						const std::string& url,   						CURLM *curl_multi)  	: LLAssetRequest(uuid, type), -	mZInitialized(false) +	  mZInitialized(false)  { +	memset(&mZStream, 0, sizeof(mZStream)); // we'll initialize this later, but for now zero the whole C-style struct to avoid debug/coverity noise  	mAssetStoragep = asp;  	mCurlHandle = NULL;  	mCurlMultiHandle = curl_multi; diff --git a/indra/llmessage/llhttpnode.h b/indra/llmessage/llhttpnode.h index 915aacb7cc..8212f58653 100644 --- a/indra/llmessage/llhttpnode.h +++ b/indra/llmessage/llhttpnode.h @@ -305,7 +305,7 @@ protected:  	~LLSimpleResponse();  private: -	LLSimpleResponse() {;} // Must be accessed through LLPointer. +        LLSimpleResponse() : mCode(0) {} // Must be accessed through LLPointer.  };  std::ostream& operator<<(std::ostream& out, const LLSimpleResponse& resp); diff --git a/indra/llmessage/llinstantmessage.cpp b/indra/llmessage/llinstantmessage.cpp index 3da41939fa..a9e1ee77ef 100644 --- a/indra/llmessage/llinstantmessage.cpp +++ b/indra/llmessage/llinstantmessage.cpp @@ -68,9 +68,11 @@ const S32 IM_TTL = 1;   * LLIMInfo   */  LLIMInfo::LLIMInfo() : +	mFromGroup(FALSE),  	mParentEstateID(0),  	mOffline(0),  	mViewerThinksToIsOnline(false), +	mIMType(IM_NOTHING_SPECIAL),  	mTimeStamp(0),  	mSource(IM_FROM_SIM),  	mTTL(IM_TTL) diff --git a/indra/llmessage/lliohttpserver.cpp b/indra/llmessage/lliohttpserver.cpp index 97134bd336..27530fbfe1 100644 --- a/indra/llmessage/lliohttpserver.cpp +++ b/indra/llmessage/lliohttpserver.cpp @@ -74,7 +74,12 @@ class LLHTTPPipe : public LLIOPipe  {  public:  	LLHTTPPipe(const LLHTTPNode& node) -		: mNode(node), mResponse(NULL), mState(STATE_INVOKE), mChainLock(0), mStatusCode(0) +		: mNode(node), +		  mResponse(NULL), +		  mState(STATE_INVOKE), +		  mChainLock(0), +		  mLockedPump(NULL), +		  mStatusCode(0)  		{ }  	virtual ~LLHTTPPipe()  	{ @@ -111,7 +116,7 @@ private:  		void nullPipe();  	private: -		Response() {;} // Must be accessed through LLPointer. +		Response() : mPipe(NULL) {} // Must be accessed through LLPointer.  		LLHTTPPipe* mPipe;  	};  	friend class Response; @@ -403,7 +408,7 @@ void LLHTTPPipe::unlockChain()  class LLHTTPResponseHeader : public LLIOPipe  {  public: -	LLHTTPResponseHeader() {} +	LLHTTPResponseHeader() : mCode(0) {}  	virtual ~LLHTTPResponseHeader() {}  protected: diff --git a/indra/llmessage/llmessagetemplate.h b/indra/llmessage/llmessagetemplate.h index d7f02ebd85..8abc0aaab2 100644 --- a/indra/llmessage/llmessagetemplate.h +++ b/indra/llmessage/llmessagetemplate.h @@ -82,7 +82,7 @@ protected:  class LLMsgBlkData  {  public: -	LLMsgBlkData(const char *name, S32 blocknum) : mOffset(-1), mBlockNumber(blocknum), mTotalSize(-1)  +        LLMsgBlkData(const char *name, S32 blocknum) : mBlockNumber(blocknum), mTotalSize(-1)   	{   		mName = (char *)name;   	} @@ -108,7 +108,6 @@ public:  		temp->addData(data, size, type, data_size);  	} -	S32									mOffset;  	S32									mBlockNumber;  	typedef LLDynamicArrayIndexed<LLMsgVarData, const char *, 8> msg_var_data_map_t;  	msg_var_data_map_t					mMemberVarData; @@ -136,7 +135,6 @@ public:  	void addDataFast(char *blockname, char *varname, const void *data, S32 size, EMsgVariableType type, S32 data_size = -1);  public: -	S32									mOffset;  	typedef std::map<char*, LLMsgBlkData*> msg_blk_data_map_t;  	msg_blk_data_map_t					mMemberBlocks;  	char								*mName; diff --git a/indra/llmessage/llmessagetemplateparser.cpp b/indra/llmessage/llmessagetemplateparser.cpp index 283547ea00..2ddbf3e0df 100644 --- a/indra/llmessage/llmessagetemplateparser.cpp +++ b/indra/llmessage/llmessagetemplateparser.cpp @@ -403,6 +403,10 @@ LLTemplateParser::LLTemplateParser(LLTemplateTokenizer & tokens):  		{  			mMessages.push_back(templatep);  		} +		else +		{ +			delete templatep; +		}  	}  	if(!tokens.wantEOF()) diff --git a/indra/llmessage/llnamevalue.cpp b/indra/llmessage/llnamevalue.cpp index 01e922eba2..43429b0ab3 100644 --- a/indra/llmessage/llnamevalue.cpp +++ b/indra/llmessage/llnamevalue.cpp @@ -963,6 +963,7 @@ std::ostream&		operator<<(std::ostream& s, const LLNameValue &a)  			U64_to_str(*a.mNameValueReference.u64, u64_string, sizeof(u64_string));  			s << u64_string;  		} +		break;  	case NVT_VEC3:  		s << *(a.mNameValueReference.vec3);  		break; diff --git a/indra/llmessage/llpacketbuffer.cpp b/indra/llmessage/llpacketbuffer.cpp index 027d35cf89..441e8ddd27 100644 --- a/indra/llmessage/llpacketbuffer.cpp +++ b/indra/llmessage/llpacketbuffer.cpp @@ -42,11 +42,14 @@  LLPacketBuffer::LLPacketBuffer(const LLHost &host, const char *datap, const S32 size) : mHost(host)  { +	mSize = 0; +	mData[0] = '!'; +  	if (size > NET_BUFFER_SIZE)  	{  		llerrs << "Sending packet > " << NET_BUFFER_SIZE << " of size " << size << llendl;  	} -	else // we previously relied on llerrs being fatal to not get here... +	else  	{  		if (datap != NULL)  		{ diff --git a/indra/llmessage/lltemplatemessagebuilder.cpp b/indra/llmessage/lltemplatemessagebuilder.cpp index 6400310c46..55379fc6fd 100644 --- a/indra/llmessage/lltemplatemessagebuilder.cpp +++ b/indra/llmessage/lltemplatemessagebuilder.cpp @@ -737,10 +737,14 @@ static S32 buildBlock(U8* buffer, S32 buffer_size, const LLMessageBlock* templat  		}  		--block_count; -		++block_iter; +		  		if (block_iter != message_data->mMemberBlocks.end())  		{ -			mbci = block_iter->second; +			++block_iter; +			if (block_iter != message_data->mMemberBlocks.end()) +			{ +				mbci = block_iter->second; +			}  		}  	} diff --git a/indra/llmessage/lltransfermanager.cpp b/indra/llmessage/lltransfermanager.cpp index d67911e8e2..d64b666ede 100644 --- a/indra/llmessage/lltransfermanager.cpp +++ b/indra/llmessage/lltransfermanager.cpp @@ -855,6 +855,7 @@ void LLTransferSourceChannel::updateTransfers()  			break;  		case LLTS_ERROR:  			llwarns << "Error in transfer dataCallback!" << llendl; +			// fall through  		case LLTS_DONE:  			// We need to clean up this transfer source.  			//llinfos << "LLTransferSourceChannel::updateTransfers() " << tsp->getID() << " done" << llendl; @@ -1195,6 +1196,7 @@ LLTransferTarget::LLTransferTarget(  	mType(type),  	mSourceType(source_type),  	mID(transfer_id), +	mChannelp(NULL),  	mGotInfo(FALSE),  	mSize(0),  	mLastPacketID(-1) diff --git a/indra/llmessage/lltransfersourceasset.cpp b/indra/llmessage/lltransfersourceasset.cpp index 7332f5c954..8f36d516d7 100644 --- a/indra/llmessage/lltransfersourceasset.cpp +++ b/indra/llmessage/lltransfersourceasset.cpp @@ -226,7 +226,10 @@ void LLTransferSourceAsset::responderCallback(LLVFS *vfs, const LLUUID& uuid, LL -LLTransferSourceParamsAsset::LLTransferSourceParamsAsset() : LLTransferSourceParams(LLTST_ASSET) +LLTransferSourceParamsAsset::LLTransferSourceParamsAsset() +	: LLTransferSourceParams(LLTST_ASSET), + +	  mAssetType(LLAssetType::AT_NONE)  {  } diff --git a/indra/llmessage/lltransfertargetfile.h b/indra/llmessage/lltransfertargetfile.h index 18b9b52062..92fb8f807c 100644 --- a/indra/llmessage/lltransfertargetfile.h +++ b/indra/llmessage/lltransfertargetfile.h @@ -40,7 +40,12 @@ typedef void (*LLTTFCompleteCallback)(const LLTSCode status, void *user_data);  class LLTransferTargetParamsFile : public LLTransferTargetParams  {  public: -	LLTransferTargetParamsFile() : LLTransferTargetParams(LLTTT_FILE) {} +	LLTransferTargetParamsFile() +		: LLTransferTargetParams(LLTTT_FILE), + +		mCompleteCallback(NULL), +		mUserData(NULL) +	{}  	void setFilename(const std::string& filename)	{ mFilename = filename; }  	void setCallback(LLTTFCompleteCallback cb, void *user_data)		{ mCompleteCallback = cb; mUserData = user_data; } diff --git a/indra/llmessage/lltransfertargetvfile.h b/indra/llmessage/lltransfertargetvfile.h index 8c2bc7e8bb..cd18d8ce3f 100644 --- a/indra/llmessage/lltransfertargetvfile.h +++ b/indra/llmessage/lltransfertargetvfile.h @@ -68,7 +68,6 @@ protected:  	LLTTVFCompleteCallback	mCompleteCallback;  	void*					mUserDatap;  	S32						mErrCode; -	LLVFSThread::handle_t	mHandle;  }; diff --git a/indra/llmessage/llxfer.cpp b/indra/llmessage/llxfer.cpp index 8404f6519d..7aa833ee32 100644 --- a/indra/llmessage/llxfer.cpp +++ b/indra/llmessage/llxfer.cpp @@ -74,6 +74,7 @@ void LLXfer::init (S32 chunk_size)  	mCallback = NULL;  	mCallbackDataHandle = NULL; +	mCallbackResult = 0;  	mBufferContainsEOF = FALSE;  	mBuffer = NULL; diff --git a/indra/llmessage/message.cpp b/indra/llmessage/message.cpp index e56d818d65..916006bc2d 100644 --- a/indra/llmessage/message.cpp +++ b/indra/llmessage/message.cpp @@ -253,6 +253,8 @@ LLMessageSystem::LLMessageSystem(const std::string& filename, U32 port,  {  	init(); +	mSendSize = 0; +  	mSystemVersionMajor = version_major;  	mSystemVersionMinor = version_minor;  	mSystemVersionPatch = version_patch; @@ -323,6 +325,8 @@ LLMessageSystem::LLMessageSystem(const std::string& filename, U32 port,  	mMaxMessageTime   = 1.f;  	mTrueReceiveSize = 0; + +	mReceiveTime = 0.f;  } diff --git a/indra/llmessage/partsyspacket.cpp b/indra/llmessage/partsyspacket.cpp index cfb3572d84..2f9e59accb 100644 --- a/indra/llmessage/partsyspacket.cpp +++ b/indra/llmessage/partsyspacket.cpp @@ -144,6 +144,8 @@ LLPartSysCompressedPacket::LLPartSysCompressedPacket()  		mData[i] = '\0';  	} +	mNumBytes = 0; +  	gSetInitDataDefaults(&mDefaults);  } | 
