From aba4f7ddc89c9d28bdd4b02735134101f40634ed Mon Sep 17 00:00:00 2001 From: Xiaohong Bao Date: Mon, 20 Jun 2011 14:01:32 -0600 Subject: fix for SH-1870: can not upload book_collection_1.dae when include textures --- indra/newview/app_settings/settings.xml | 11 +++++++++++ indra/newview/llmeshrepository.cpp | 10 ++++++---- indra/newview/llmeshrepository.h | 3 +++ 3 files changed, 20 insertions(+), 4 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index 76fecdf05e..52064c96f2 100755 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -5611,6 +5611,17 @@ Value 0 + MeshUploadTimeOut + + Comment + Maximum time in seconds for llcurl to execute a mesh uoloading request + Persist + 1 + Type + S32 + Value + 600 + MigrateCacheDirectory Comment diff --git a/indra/newview/llmeshrepository.cpp b/indra/newview/llmeshrepository.cpp index 6e0722bcf9..2b340fc54d 100755 --- a/indra/newview/llmeshrepository.cpp +++ b/indra/newview/llmeshrepository.cpp @@ -1383,6 +1383,8 @@ LLMeshUploadThread::LLMeshUploadThread(LLMeshUploadThread::instance_list& data, mWholeModelFeeCapability = gAgent.getRegion()->getCapability("NewFileAgentInventory"); mOrigin += gAgent.getAtAxis() * scale.magVec(); + + mMeshUploadTimeOut = gSavedSettings.getS32("MeshUploadTimeOut") ; } LLMeshUploadThread::~LLMeshUploadThread() @@ -1686,7 +1688,7 @@ void LLMeshUploadThread::doWholeModelUpload() mPendingUploads++; LLCurlRequest::headers_t headers; mCurlRequest->post(mWholeModelFeeCapability, headers, model_data, - new LLWholeModelFeeResponder(this,model_data)); + new LLWholeModelFeeResponder(this,model_data), mMeshUploadTimeOut); do { @@ -1705,7 +1707,7 @@ void LLMeshUploadThread::doWholeModelUpload() LLSD body = full_model_data["asset_resources"]; dump_llsd_to_file(body,make_dump_name("whole_model_body_",dump_num)); mCurlRequest->post(mWholeModelUploadURL, headers, body, - new LLWholeModelUploadResponder(this, model_data)); + new LLWholeModelUploadResponder(this, model_data), mMeshUploadTimeOut); do { mCurlRequest->process(); @@ -2874,7 +2876,7 @@ void LLMeshUploadThread::doUploadModel(LLMeshUploadData& data) LLCurlRequest::headers_t headers; mPendingUploads++; - mCurlRequest->post(data.mRSVP, headers, data.mAssetData, new LLMeshUploadResponder(data, this)); + mCurlRequest->post(data.mRSVP, headers, data.mAssetData, new LLMeshUploadResponder(data, this), mMeshUploadTimeOut); } } @@ -2906,7 +2908,7 @@ void LLMeshUploadThread::doUploadTexture(LLTextureUploadData& data) LLCurlRequest::headers_t headers; mPendingUploads++; - mCurlRequest->post(data.mRSVP, headers, data.mAssetData, new LLTextureUploadResponder(data, this)); + mCurlRequest->post(data.mRSVP, headers, data.mAssetData, new LLTextureUploadResponder(data, this), mMeshUploadTimeOut); } } diff --git a/indra/newview/llmeshrepository.h b/indra/newview/llmeshrepository.h index f237c3a60e..f56734a7de 100644 --- a/indra/newview/llmeshrepository.h +++ b/indra/newview/llmeshrepository.h @@ -356,6 +356,9 @@ public: class LLMeshUploadThread : public LLThread { +private: + S32 mMeshUploadTimeOut ; //maximum time in seconds to execute an uploading request. + public: class DecompRequest : public LLPhysicsDecomp::Request { -- cgit v1.2.3