summaryrefslogtreecommitdiff
path: root/indra/llcommon/llmemory.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llcommon/llmemory.cpp')
-rw-r--r--indra/llcommon/llmemory.cpp31
1 files changed, 1 insertions, 30 deletions
diff --git a/indra/llcommon/llmemory.cpp b/indra/llcommon/llmemory.cpp
index 1884d6f04f..7cf4bc0706 100644
--- a/indra/llcommon/llmemory.cpp
+++ b/indra/llcommon/llmemory.cpp
@@ -35,7 +35,7 @@
# include <sys/types.h>
# include <mach/task.h>
# include <mach/mach_init.h>
-#elif LL_LINUX || LL_SOLARIS
+#elif LL_LINUX
# include <unistd.h>
#endif
@@ -309,35 +309,6 @@ U64 LLMemory::getCurrentRSS()
return rss;
}
-#elif LL_SOLARIS
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <fcntl.h>
-#define _STRUCTURED_PROC 1
-#include <sys/procfs.h>
-
-U64 LLMemory::getCurrentRSS()
-{
- char path [LL_MAX_PATH]; /* Flawfinder: ignore */
-
- sprintf(path, "/proc/%d/psinfo", (int)getpid());
- int proc_fd = -1;
- if((proc_fd = open(path, O_RDONLY)) == -1){
- LL_WARNS() << "LLmemory::getCurrentRSS() unable to open " << path << ". Returning 0 RSS!" << LL_ENDL;
- return 0;
- }
- psinfo_t proc_psinfo;
- if(read(proc_fd, &proc_psinfo, sizeof(psinfo_t)) != sizeof(psinfo_t)){
- LL_WARNS() << "LLmemory::getCurrentRSS() Unable to read from " << path << ". Returning 0 RSS!" << LL_ENDL;
- close(proc_fd);
- return 0;
- }
-
- close(proc_fd);
-
- return((U64)proc_psinfo.pr_rssize * 1024);
-}
-
#else
U64 LLMemory::getCurrentRSS()