aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/llcommon/lluuid.cpp
diff options
context:
space:
mode:
authorJacek Antonelli2009-04-30 13:04:20 -0500
committerJacek Antonelli2009-04-30 13:07:16 -0500
commitca8149ca6d157eb4b5fc8ba0e5ba3a6e56f72e7e (patch)
tree8348301d0ac44a524f1819b777686bf086907d76 /linden/indra/llcommon/lluuid.cpp
parentSecond Life viewer sources 1.22.11 (diff)
downloadmeta-impy-ca8149ca6d157eb4b5fc8ba0e5ba3a6e56f72e7e.zip
meta-impy-ca8149ca6d157eb4b5fc8ba0e5ba3a6e56f72e7e.tar.gz
meta-impy-ca8149ca6d157eb4b5fc8ba0e5ba3a6e56f72e7e.tar.bz2
meta-impy-ca8149ca6d157eb4b5fc8ba0e5ba3a6e56f72e7e.tar.xz
Second Life viewer sources 1.23.0-RC
Diffstat (limited to '')
-rw-r--r--linden/indra/llcommon/lluuid.cpp25
1 files changed, 21 insertions, 4 deletions
diff --git a/linden/indra/llcommon/lluuid.cpp b/linden/indra/llcommon/lluuid.cpp
index 4f0f95e..bcbae06 100644
--- a/linden/indra/llcommon/lluuid.cpp
+++ b/linden/indra/llcommon/lluuid.cpp
@@ -16,7 +16,8 @@
16 * There are special exceptions to the terms and conditions of the GPL as 16 * There are special exceptions to the terms and conditions of the GPL as
17 * it is applied to this Source Code. View the full text of the exception 17 * it is applied to this Source Code. View the full text of the exception
18 * in the file doc/FLOSS-exception.txt in this software distribution, or 18 * in the file doc/FLOSS-exception.txt in this software distribution, or
19 * online at http://secondlifegrid.net/programs/open_source/licensing/flossexception 19 * online at
20 * http://secondlifegrid.net/programs/open_source/licensing/flossexception
20 * 21 *
21 * By copying, modifying or distributing this software, you acknowledge 22 * By copying, modifying or distributing this software, you acknowledge
22 * that you have read and understood your obligations described above, 23 * that you have read and understood your obligations described above,
@@ -208,7 +209,7 @@ std::string LLUUID::asString() const
208 209
209BOOL LLUUID::set(const char* in_string, BOOL emit) 210BOOL LLUUID::set(const char* in_string, BOOL emit)
210{ 211{
211 return set(ll_safe_string(in_string)); 212 return set(ll_safe_string(in_string),emit);
212} 213}
213 214
214BOOL LLUUID::set(const std::string& in_string, BOOL emit) 215BOOL LLUUID::set(const std::string& in_string, BOOL emit)
@@ -230,7 +231,7 @@ BOOL LLUUID::set(const std::string& in_string, BOOL emit)
230 { 231 {
231 if(emit) 232 if(emit)
232 { 233 {
233 llinfos << "Warning! Using broken UUID string format" << llendl; 234 llwarns << "Warning! Using broken UUID string format" << llendl;
234 } 235 }
235 broken_format = TRUE; 236 broken_format = TRUE;
236 } 237 }
@@ -239,7 +240,8 @@ BOOL LLUUID::set(const std::string& in_string, BOOL emit)
239 // Bad UUID string. Spam as INFO, as most cases we don't care. 240 // Bad UUID string. Spam as INFO, as most cases we don't care.
240 if(emit) 241 if(emit)
241 { 242 {
242 llinfos << "Bad UUID string: " << in_string << llendl; 243 //don't spam the logs because a resident can't spell.
244 llwarns << "Bad UUID string: " << in_string << llendl;
243 } 245 }
244 setNull(); 246 setNull();
245 return FALSE; 247 return FALSE;
@@ -908,6 +910,21 @@ BOOL LLUUID::parseUUID(const std::string& buf, LLUUID* value)
908 return FALSE; 910 return FALSE;
909} 911}
910 912
913//static
914LLUUID LLUUID::generateNewID(std::string hash_string)
915{
916 LLUUID new_id;
917 if (hash_string.empty())
918 {
919 new_id.generate();
920 }
921 else
922 {
923 new_id.generate(hash_string);
924 }
925 return new_id;
926}
927
911LLAssetID LLTransactionID::makeAssetID(const LLUUID& session) const 928LLAssetID LLTransactionID::makeAssetID(const LLUUID& session) const
912{ 929{
913 LLAssetID result; 930 LLAssetID result;