summaryrefslogtreecommitdiff
path: root/indra/llcommon
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llcommon')
-rw-r--r--indra/llcommon/llavatarname.cpp10
-rw-r--r--indra/llcommon/llprocesslauncher.cpp24
-rw-r--r--indra/llcommon/llversionviewer.h4
3 files changed, 30 insertions, 8 deletions
diff --git a/indra/llcommon/llavatarname.cpp b/indra/llcommon/llavatarname.cpp
index ad1845d387..ba3dd6d6b4 100644
--- a/indra/llcommon/llavatarname.cpp
+++ b/indra/llcommon/llavatarname.cpp
@@ -90,14 +90,16 @@ void LLAvatarName::fromLLSD(const LLSD& sd)
std::string LLAvatarName::getCompleteName() const
{
std::string name;
- if (!mUsername.empty())
+ if (mUsername.empty() || mIsDisplayNameDefault)
+ // If the display name feature is off
+ // OR this particular display name is defaulted (i.e. based on user name),
+ // then display only the easier to read instance of the person's name.
{
- name = mDisplayName + " (" + mUsername + ")";
+ name = mDisplayName;
}
else
{
- // ...display names are off, legacy name is in mDisplayName
- name = mDisplayName;
+ name = mDisplayName + " (" + mUsername + ")";
}
return name;
}
diff --git a/indra/llcommon/llprocesslauncher.cpp b/indra/llcommon/llprocesslauncher.cpp
index 4b0f6b0251..10950181fd 100644
--- a/indra/llcommon/llprocesslauncher.cpp
+++ b/indra/llcommon/llprocesslauncher.cpp
@@ -103,10 +103,30 @@ int LLProcessLauncher::launch(void)
char *args2 = new char[args.size() + 1];
strcpy(args2, args.c_str());
- if( ! CreateProcessA( NULL, args2, NULL, NULL, FALSE, 0, NULL, NULL, &sinfo, &pinfo ) )
+ const char * working_directory = 0;
+ if(!mWorkingDir.empty()) working_directory = mWorkingDir.c_str();
+ if( ! CreateProcessA( NULL, args2, NULL, NULL, FALSE, 0, NULL, working_directory, &sinfo, &pinfo ) )
{
- // TODO: do better than returning the OS-specific error code on failure...
result = GetLastError();
+
+ LPTSTR error_str = 0;
+ if(
+ FormatMessage( FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM,
+ NULL,
+ result,
+ 0,
+ (LPTSTR)&error_str,
+ 0,
+ NULL)
+ != 0)
+ {
+ char message[256];
+ wcstombs(message, error_str, 256);
+ message[255] = 0;
+ llwarns << "CreateProcessA failed: " << message << llendl;
+ LocalFree(error_str);
+ }
+
if(result == 0)
{
// Make absolutely certain we return a non-zero value on failure.
diff --git a/indra/llcommon/llversionviewer.h b/indra/llcommon/llversionviewer.h
index 7703132d90..117d96ffa6 100644
--- a/indra/llcommon/llversionviewer.h
+++ b/indra/llcommon/llversionviewer.h
@@ -28,8 +28,8 @@
#define LL_LLVERSIONVIEWER_H
const S32 LL_VERSION_MAJOR = 2;
-const S32 LL_VERSION_MINOR = 7;
-const S32 LL_VERSION_PATCH = 0;
+const S32 LL_VERSION_MINOR = 6;
+const S32 LL_VERSION_PATCH = 1;
const S32 LL_VERSION_BUILD = 0;
const char * const LL_CHANNEL = "Second Life Developer";