summaryrefslogtreecommitdiff
path: root/indra/llcommon
AgeCommit message (Collapse)Author
2011-07-20fix for crash when adding new fast timersRichard Nelson
2011-07-20still trying to fix channelsBrad Payne (Vir Linden)
2011-07-19More FormatMessage compile errors, try again to fixNat Goodspeed
2011-07-19Fix copy/paste error in swiped FormatMessage() example code.Nat Goodspeed
2011-07-19Per Josh's comments in http://codereview.lindenlab.com/6510035/Nat Goodspeed
Instead of low-level open(O_CREAT | O_EXCL) loop on all platforms, use GetTempFileName() on Windows and mkstemp() elsewhere. Don't append a final newline to NamedTempFile: use caller's data literally. Tweak a couple comments.
2011-07-18increment viewer version to 2.8.2Oz Linden
2011-07-17Decided against using Boost.Filesystem, remove from linkNat Goodspeed
2011-07-16Use raw-string syntax for other Windows pathnames inserted to Python.Nat Goodspeed
2011-07-16Use raw-string syntax for Python string containing Windows pathname.Nat Goodspeed
Consider this pathname for llsdserialize_test.cpp: C:\nats\indra\llcommon\tests\llsdserialize_test.cpp Embed that in a Python string literal: 'C:\nats\indra\llcommon\tests\llsdserialize_test.cpp' and you get a string containing: C: ats\indra\llcommon ests\llsdserialize_test.cpp where the \n became a newline and the \t became a tab character. Hopefully Python raw-string syntax r'C:\etc\etc' works better.
2011-07-15Use C++ __FILE__ rather than Python __file__ to find indra work area.Nat Goodspeed
In this case, the Python code in question is being written from a C++ string literal to a temp script file in a platform-dependent temp directory -- so the Python __file__ value tells you nothing about the location of the repository checkout. Embedding __FILE__ from the containing C++ source file works better.
2011-07-15Merge for STORM-1482Aaron Stone
2011-07-15If we're going to need indra.base.llsd, have to munge sys.path.Nat Goodspeed
And at that point, the Python logic needed to bring in the llsd module is big enough to warrant capturing it in a separate string variable common to multiple tests.
2011-07-15Not all TC agents have llbase.llsd, fall back to indra.base.llsdNat Goodspeed
2011-07-15Try again to pacify VS fatal warning.Nat Goodspeed
2011-07-15Muzzle VS warningNat Goodspeed
2011-07-15merge changes for storm-1509Oz Linden
2011-07-15Add test to verify Python-to-C++ LLSD notation sequence.Nat Goodspeed
Verify that an LLSD::String containing newlines works; verify that newlines between items are accepted.
2011-07-15Add test to verify C++-to-Python LLSD notation sequence.Nat Goodspeed
Write a sequence of LLSDSerialize::toNotation() calls separated by newlines to a data file, then read lines and parse using llbase.llsd.parse(). Verify that this produces expected data even when one item is a string containing newlines. Generalize python() helper function to allow using any of the NamedTempFile constructor forms. Allow specifying expected Python rc (default 0) and use this to verify an intentional sys.exit(17). This is better than previous sys.exit(0) test because when, at one point, NamedTempFile failed to write file data, running Python on an empty script file still terminates with rc 0. A nonzero rc verifies that we've written the file, that Python is running it and that we're retrieving its rc.
2011-07-15Change NamedTempScript to NamedTempFile; allow streaming to it.Nat Goodspeed
The only thing about NamedTempScript that was specific to script files was the hardcoded ".py" extension. Renaming it to NamedTempFile with an explicit extension argument addresses that. Allow constructing NamedTempFile with either a std::string, as before, or an expression of the form (lambda::_1 << some << stuff). If Linden's Boost package included the Boost.Iostreams lib, we could even stream such an expression directly to an ostream constructed around the fd. But oh well.
2011-07-14Pacify Linux gcc more thoroughly.Nat Goodspeed
2011-07-14#include correct headers for Windows _open() et al.Nat Goodspeed
Also mollify Linux build, which gets alarmed when you implicitly ignore write()'s return value. Ignore it explicitly.
2011-07-14Avoid Boost.Filesystem: Boost package improperly built on Windows?Nat Goodspeed
Seems Linden's Boost package and the viewer build might use different settings of the /Zc:wchar_t switch. Anyway, this implementation using open(O_CREAT | O_EXCL) should be more robust. I'm surprised Boost.Filesystem doesn't seem to offer "create a unique file"; all I found was "generate a random filename fairly likely to be unique."
2011-07-14wstring_to_utf8str() accepts LLWString rather than std::wstring.Nat Goodspeed
2011-07-14Use Linden wstring-to-string conversion, not boost::filesystem's.Nat Goodspeed
On Windows, calling boost::filesystem::path::string() implicitly requests code conversion between std::wstring (the boost::filesystem::path::string_type selected on Windows) and std::string. At least for integration-test program, that produces link errors. Use Linden's wstring_to_utf8str() instead.
2011-07-14Attempt to fix minor build errors on Windows.Nat Goodspeed
2011-07-14Eliminate use of PATH_MAX, which is bogus anyway.Nat Goodspeed
2011-07-14New llsdserialize_test logic needs Boost.Filesystem library.Nat Goodspeed
That, in turn, needs Boost.System library.
2011-07-14Work around broken Windows command-line processing.Nat Goodspeed
It's wonderful that the Python interpreter will accept a whole multi-line script as a composite -c argument... but because Windows command-line processing is fundamentally flawed, we simply can't count on it for Windows. Instead, accept script text, write a temporary script file in a system- dependent temp directory, ask Python to run that script and delete the file. Also, on Windows, use _spawnl(), much simpler than adding bizarre Windows wait logic to LLProcessLauncher. Use LLProcessLauncher only on Mac & Linux, with waitpid() to capture rc.
2011-07-13Still trying to fix Windows header-file-order problem.Nat Goodspeed
2011-07-13Attempt to fix confusing header-file-order problems on Windows.Nat Goodspeed
2011-07-13Introduce support for C++ integration tests running Python scripts.Nat Goodspeed
This is in its infancy; tested on Mac; needs to be ironed out on Windows and Linux. Goal is to test at least some cross-language LLSD serialization.
2011-07-12CHOP-753: Eliminate redundant array-of-pair-arrays in LLMemoryInfo.Nat Goodspeed
(per Monty code review) The notion of storing LLMemoryInfo data both as an LLSD::Map and an LLSD::Array of pair arrays arose from a (possibly misguided) desire to continue producing stats output into the viewer log in the same order it always used to be produced. There is no evidence that anyone cares about the order of those stats in the log; there is no other use case for preserving order. At Monty's recommendation, eliminate generating and storing the array-of-pair-arrays form: directly store LLSD::Map.
2011-07-12Merge for STORM-1482Aaron Stone
2011-07-12STORM-1482 The Viewer shouldn't overwrite the crash behavior settings, some ↵Aaron Stone
cleanups to the crash reporters, and the ability to use --set GroupName.SettingName to set parameters outside of the (default) Global settings group.
2011-07-12CHOP-753: Defend against boost::regex exceptions.Nat Goodspeed
(per Monty code review) Explain why we intentionally don't suppress exceptions from boost::regex objects constructed with string literals. Catch std::runtime_error from boost::regex_search() and boost::regex_match(); log and return false.
2011-07-12CHOP-753: make getAvailableMemoryKB() only load data on Windows.Nat Goodspeed
(per Monty code review) Other platforms return -1 anyway, so don't need to call load methods.
2011-07-11CHOP-753: Add classic-C-style diagnostics around popen("vm_stat").Nat Goodspeed
On Mac, where LLMemoryInfo relies on a child process rather than any sort of internal system API, try to produce more informative LL_WARNS output if popen() fails to run vm_stat, or if vm_stat terminates with nonzero rc.
2011-07-11CHOP-753: Add timestamp to LLMemoryInfo's LLSD stats block.Nat Goodspeed
For postprocessing these stats, we'll want the time at which they were captured. We'll want the current framerate too, but handle that at a higher level.
2011-07-11increment viewer version to 2.8.1Oz Linden
2011-07-09increment version to 2.8.0Oz Linden
2011-07-07Automated merge with http://hg.secondlife.com/viewer-developmentRichard Linden
2011-07-07CHOP-753: have to cast pointer passed to GetProcessMemoryInfo().Nat Goodspeed
GetProcessMemoryInfo() is prototyped with PROCESS_MEMORY_COUNTERS*, so to accept PROCESS_MEMORY_COUNTERS_EX* as documented, have to cast.
2011-07-07CHOP-753: uh, Microsoft docs lied about header file to use?Nat Goodspeed
Remove <kfuncs.h>, documented header file for GetCurrentProcess().
2011-07-07CHOP-753: add stats from GetProcessMemoryInfo() on Windows.Nat Goodspeed
Introduce StatsArray helper class to facilitate accumulating stats in the array-of-pair-arrays form cached internally by LLMemoryInfo.
2011-07-06Automated merge with http://hg.secondlife.com/viewer-developmentNat Goodspeed
2011-07-05CHOP-753: On Windows, add GetPerformanceInfo to LLMemoryInfo stats.Nat Goodspeed
So far we've only been querying GlobalMemoryStatusEx(), but GetPerformanceInfo() delivers a bunch more memory-related stats that may be pertinent. Try capturing those too. May not yet compile on Windows...
2011-06-30CHOP-753: Fix compile errors in LLMemoryInfo Windows-specific code.Nat Goodspeed
2011-06-30CHOP-753: Reduce redundancy in LLMemoryInfo.Nat Goodspeed
Recast stream() to display data from LLSD array rather than reinvoking OS operations used to capture it. Make refresh() cache LLSD data in map form as well as array; fetch items from that in a few places to avoid going back to OS.
2011-06-30CHOP-753: Fix errors in LLMemoryInfo Mac-specific code.Nat Goodspeed
Handle conversion errors (boost::bad_lexical_cast). Glean additional LLSD statistics from vm_stat output.
2011-06-29CHOP-753: fix minor compilation errors on LinuxNat Goodspeed