Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Alchemy Viewer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package registry
Operate
Terraform modules
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Silent mode is enabled
All outbound communications are blocked.
Learn more
.
Show more breadcrumbs
Alchemy Viewer
Alchemy Viewer
Commits
270fe6e3
Commit
270fe6e3
authored
5 years ago
by
Rye Mutt
Browse files
Options
Downloads
Patches
Plain Diff
More small opts to LLSD behavior
parent
00de6936
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
indra/newview/llinventorymodelbackgroundfetch.cpp
+9
-36
9 additions, 36 deletions
indra/newview/llinventorymodelbackgroundfetch.cpp
with
9 additions
and
36 deletions
indra/newview/llinventorymodelbackgroundfetch.cpp
+
9
−
36
View file @
270fe6e3
...
@@ -571,11 +571,9 @@ void LLInventoryModelBackgroundFetch::bulkFetch()
...
@@ -571,11 +571,9 @@ void LLInventoryModelBackgroundFetch::bulkFetch()
bool
LLInventoryModelBackgroundFetch
::
fetchQueueContainsNoDescendentsOf
(
const
LLUUID
&
cat_id
)
const
bool
LLInventoryModelBackgroundFetch
::
fetchQueueContainsNoDescendentsOf
(
const
LLUUID
&
cat_id
)
const
{
{
for
(
fetch_queue_t
::
const_iterator
it
=
mFetchQueue
.
begin
();
for
(
const
auto
&
item
:
mFetchQueue
)
it
!=
mFetchQueue
.
end
();
++
it
)
{
{
const
LLUUID
&
fetch_id
=
(
*
it
)
.
mUUID
;
const
LLUUID
&
fetch_id
=
item
.
mUUID
;
if
(
gInventory
.
isObjectDescendentOf
(
fetch_id
,
cat_id
))
if
(
gInventory
.
isObjectDescendentOf
(
fetch_id
,
cat_id
))
return
false
;
return
false
;
}
}
...
@@ -664,12 +662,8 @@ void BGFolderHttpHandler::processData(LLSD & content, LLCore::HttpResponse * res
...
@@ -664,12 +662,8 @@ void BGFolderHttpHandler::processData(LLSD & content, LLCore::HttpResponse * res
{
{
LLSD
folders
(
content
[
"folders"
]);
LLSD
folders
(
content
[
"folders"
]);
for
(
LLSD
::
array_const_iterator
folder_it
=
folders
.
beginArray
();
for
(
const
auto
&
folder_sd
:
folders
.
array
())
folder_it
!=
folders
.
endArray
();
++
folder_it
)
{
{
LLSD
folder_sd
(
*
folder_it
);
//LLUUID agent_id = folder_sd["agent_id"];
//LLUUID agent_id = folder_sd["agent_id"];
//if(agent_id != gAgent.getID()) //This should never happen.
//if(agent_id != gAgent.getID()) //This should never happen.
...
@@ -690,16 +684,12 @@ void BGFolderHttpHandler::processData(LLSD & content, LLCore::HttpResponse * res
...
@@ -690,16 +684,12 @@ void BGFolderHttpHandler::processData(LLSD & content, LLCore::HttpResponse * res
LLSD
items
(
folder_sd
[
"items"
]);
LLSD
items
(
folder_sd
[
"items"
]);
LLPointer
<
LLViewerInventoryItem
>
titem
=
new
LLViewerInventoryItem
;
LLPointer
<
LLViewerInventoryItem
>
titem
=
new
LLViewerInventoryItem
;
for
(
LLSD
::
array_const_iterator
item_it
=
items
.
beginArray
();
for
(
const
auto
&
item
:
items
.
array
())
item_it
!=
items
.
endArray
();
++
item_it
)
{
{
const
LLUUID
lost_uuid
(
gInventory
.
findCategoryUUIDForType
(
LLFolderType
::
FT_LOST_AND_FOUND
));
const
LLUUID
lost_uuid
(
gInventory
.
findCategoryUUIDForType
(
LLFolderType
::
FT_LOST_AND_FOUND
));
if
(
lost_uuid
.
notNull
())
if
(
lost_uuid
.
notNull
())
{
{
LLSD
item
(
*
item_it
);
titem
->
unpackMessage
(
item
);
titem
->
unpackMessage
(
item
);
LLInventoryModel
::
update_list_t
update
;
LLInventoryModel
::
update_list_t
update
;
...
@@ -721,11 +711,8 @@ void BGFolderHttpHandler::processData(LLSD & content, LLCore::HttpResponse * res
...
@@ -721,11 +711,8 @@ void BGFolderHttpHandler::processData(LLSD & content, LLCore::HttpResponse * res
}
}
LLSD
categories
(
folder_sd
[
"categories"
]);
LLSD
categories
(
folder_sd
[
"categories"
]);
for
(
LLSD
::
array_const_iterator
category_it
=
categories
.
beginArray
();
for
(
const
auto
&
category
:
categories
.
array
())
category_it
!=
categories
.
endArray
();
++
category_it
)
{
{
LLSD
category
(
*
category_it
);
tcategory
->
fromLLSD
(
category
);
tcategory
->
fromLLSD
(
category
);
const
bool
recursive
(
getIsRecursive
(
tcategory
->
getUUID
()));
const
bool
recursive
(
getIsRecursive
(
tcategory
->
getUUID
()));
...
@@ -741,11 +728,8 @@ void BGFolderHttpHandler::processData(LLSD & content, LLCore::HttpResponse * res
...
@@ -741,11 +728,8 @@ void BGFolderHttpHandler::processData(LLSD & content, LLCore::HttpResponse * res
LLSD
items
(
folder_sd
[
"items"
]);
LLSD
items
(
folder_sd
[
"items"
]);
LLPointer
<
LLViewerInventoryItem
>
titem
=
new
LLViewerInventoryItem
;
LLPointer
<
LLViewerInventoryItem
>
titem
=
new
LLViewerInventoryItem
;
for
(
LLSD
::
array_const_iterator
item_it
=
items
.
beginArray
();
for
(
const
auto
&
item
:
items
.
array
())
item_it
!=
items
.
endArray
();
++
item_it
)
{
{
LLSD
item
(
*
item_it
);
titem
->
unpackMessage
(
item
);
titem
->
unpackMessage
(
item
);
gInventory
.
updateItem
(
titem
);
gInventory
.
updateItem
(
titem
);
...
@@ -765,13 +749,8 @@ void BGFolderHttpHandler::processData(LLSD & content, LLCore::HttpResponse * res
...
@@ -765,13 +749,8 @@ void BGFolderHttpHandler::processData(LLSD & content, LLCore::HttpResponse * res
if
(
content
.
has
(
"bad_folders"
))
if
(
content
.
has
(
"bad_folders"
))
{
{
LLSD
bad_folders
(
content
[
"bad_folders"
]);
LLSD
bad_folders
(
content
[
"bad_folders"
]);
for
(
LLSD
::
array_const_iterator
folder_it
=
bad_folders
.
beginArray
();
for
(
const
auto
&
folder_sd
:
bad_folders
.
array
())
folder_it
!=
bad_folders
.
endArray
();
++
folder_it
)
{
{
// *TODO: Stop copying data [ed: this isn't copying data]
LLSD
folder_sd
(
*
folder_it
);
// These folders failed on the dataserver. We probably don't want to retry them.
// These folders failed on the dataserver. We probably don't want to retry them.
LL_WARNS
(
LOG_INV
)
<<
"Folder "
<<
folder_sd
[
"folder_id"
].
asString
()
LL_WARNS
(
LOG_INV
)
<<
"Folder "
<<
folder_sd
[
"folder_id"
].
asString
()
<<
"Error: "
<<
folder_sd
[
"error"
].
asString
()
<<
LL_ENDL
;
<<
"Error: "
<<
folder_sd
[
"error"
].
asString
()
<<
LL_ENDL
;
...
@@ -807,11 +786,8 @@ void BGFolderHttpHandler::processFailure(LLCore::HttpStatus status, LLCore::Http
...
@@ -807,11 +786,8 @@ void BGFolderHttpHandler::processFailure(LLCore::HttpStatus status, LLCore::Http
if
(
false
)
if
(
false
)
{
{
// timed out or curl failure
// timed out or curl failure
for
(
LLSD
::
array_const_iterator
folder_it
=
mRequestSD
[
"folders"
].
beginArray
();
for
(
const
auto
&
folder_sd
:
mRequestSD
[
"folders"
].
array
())
folder_it
!=
mRequestSD
[
"folders"
].
endArray
();
++
folder_it
)
{
{
LLSD
folder_sd
(
*
folder_it
);
LLUUID
folder_id
(
folder_sd
[
"folder_id"
].
asUUID
());
LLUUID
folder_id
(
folder_sd
[
"folder_id"
].
asUUID
());
const
BOOL
recursive
=
getIsRecursive
(
folder_id
);
const
BOOL
recursive
=
getIsRecursive
(
folder_id
);
fetcher
->
addRequestAtFront
(
folder_id
,
recursive
,
true
);
fetcher
->
addRequestAtFront
(
folder_id
,
recursive
,
true
);
...
@@ -844,11 +820,8 @@ void BGFolderHttpHandler::processFailure(const char * const reason, LLCore::Http
...
@@ -844,11 +820,8 @@ void BGFolderHttpHandler::processFailure(const char * const reason, LLCore::Http
LLInventoryModelBackgroundFetch
*
fetcher
=
LLInventoryModelBackgroundFetch
::
getInstance
();
LLInventoryModelBackgroundFetch
*
fetcher
=
LLInventoryModelBackgroundFetch
::
getInstance
();
if
(
true
)
if
(
true
)
{
{
for
(
LLSD
::
array_const_iterator
folder_it
=
mRequestSD
[
"folders"
].
beginArray
();
for
(
const
auto
&
folder_sd
:
mRequestSD
[
"folders"
].
array
())
folder_it
!=
mRequestSD
[
"folders"
].
endArray
();
++
folder_it
)
{
{
LLSD
folder_sd
(
*
folder_it
);
LLUUID
folder_id
(
folder_sd
[
"folder_id"
].
asUUID
());
LLUUID
folder_id
(
folder_sd
[
"folder_id"
].
asUUID
());
const
BOOL
recursive
=
getIsRecursive
(
folder_id
);
const
BOOL
recursive
=
getIsRecursive
(
folder_id
);
fetcher
->
addRequestAtFront
(
folder_id
,
recursive
,
true
);
fetcher
->
addRequestAtFront
(
folder_id
,
recursive
,
true
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment