diff options
author | Jacek Antonelli | 2008-08-15 23:44:50 -0500 |
---|---|---|
committer | Jacek Antonelli | 2008-08-15 23:44:50 -0500 |
commit | 89fe5dab825a62a0e3fd8d248cbc91c65eb2a426 (patch) | |
tree | bcff14b7888d04a2fec799c59369f6095224bd08 /linden/indra/llvfs/llvfsthread.h | |
parent | Second Life viewer sources 1.13.3.2 (diff) | |
download | meta-impy-89fe5dab825a62a0e3fd8d248cbc91c65eb2a426.zip meta-impy-89fe5dab825a62a0e3fd8d248cbc91c65eb2a426.tar.gz meta-impy-89fe5dab825a62a0e3fd8d248cbc91c65eb2a426.tar.bz2 meta-impy-89fe5dab825a62a0e3fd8d248cbc91c65eb2a426.tar.xz |
Second Life viewer sources 1.14.0.0
Diffstat (limited to 'linden/indra/llvfs/llvfsthread.h')
-rw-r--r-- | linden/indra/llvfs/llvfsthread.h | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/linden/indra/llvfs/llvfsthread.h b/linden/indra/llvfs/llvfsthread.h index c3a5a55..3c90808 100644 --- a/linden/indra/llvfs/llvfsthread.h +++ b/linden/indra/llvfs/llvfsthread.h | |||
@@ -83,15 +83,14 @@ public: | |||
83 | } | 83 | } |
84 | std::string getFilename() | 84 | std::string getFilename() |
85 | { | 85 | { |
86 | char tbuf[40]; | 86 | char tbuf[40]; /* Flawfinder: ignore */ |
87 | mFileID.toString(tbuf); | 87 | mFileID.toString(tbuf); |
88 | return std::string(tbuf); | 88 | return std::string(tbuf); |
89 | } | 89 | } |
90 | 90 | ||
91 | /*virtual*/ void finishRequest(); | 91 | /*virtual*/ bool processRequest(); |
92 | /*virtual*/ void finishRequest(bool completed); | ||
92 | /*virtual*/ void deleteRequest(); | 93 | /*virtual*/ void deleteRequest(); |
93 | |||
94 | bool processIO(); | ||
95 | 94 | ||
96 | private: | 95 | private: |
97 | operation_t mOperation; | 96 | operation_t mOperation; |
@@ -109,19 +108,20 @@ public: | |||
109 | //------------------------------------------------------------------------ | 108 | //------------------------------------------------------------------------ |
110 | public: | 109 | public: |
111 | static std::string sDataPath; | 110 | static std::string sDataPath; |
112 | static void setDataPath(const std::string& path) { sDataPath = path; } | 111 | static LLVFSThread* sLocal; // Default worker thread |
113 | 112 | ||
114 | public: | 113 | public: |
115 | LLVFSThread(bool threaded = TRUE, bool runalways = TRUE); | 114 | LLVFSThread(bool threaded = TRUE); |
116 | ~LLVFSThread(); | 115 | ~LLVFSThread(); |
117 | 116 | ||
118 | // Return a Request handle | 117 | // Return a Request handle |
119 | handle_t read(LLVFS* vfs, const LLUUID &file_id, const LLAssetType::EType file_type, | 118 | handle_t read(LLVFS* vfs, const LLUUID &file_id, const LLAssetType::EType file_type, /* Flawfinder: ignore */ |
120 | U8* buffer, S32 offset, S32 numbytes, U32 pri=PRIORITY_NORMAL, U32 flags = 0); | 119 | U8* buffer, S32 offset, S32 numbytes, U32 pri=PRIORITY_NORMAL, U32 flags = 0); |
121 | handle_t write(LLVFS* vfs, const LLUUID &file_id, const LLAssetType::EType file_type, | 120 | handle_t write(LLVFS* vfs, const LLUUID &file_id, const LLAssetType::EType file_type, |
122 | U8* buffer, S32 offset, S32 numbytes, U32 flags); | 121 | U8* buffer, S32 offset, S32 numbytes, U32 flags); |
123 | handle_t rename(LLVFS* vfs, const LLUUID &file_id, const LLAssetType::EType file_type, | 122 | // SJB: rename seems to have issues, especially when threaded |
124 | const LLUUID &new_id, const LLAssetType::EType new_type, U32 flags); | 123 | // handle_t rename(LLVFS* vfs, const LLUUID &file_id, const LLAssetType::EType file_type, |
124 | // const LLUUID &new_id, const LLAssetType::EType new_type, U32 flags); | ||
125 | // Return number of bytes read | 125 | // Return number of bytes read |
126 | S32 readImmediate(LLVFS* vfs, const LLUUID &file_id, const LLAssetType::EType file_type, | 126 | S32 readImmediate(LLVFS* vfs, const LLUUID &file_id, const LLAssetType::EType file_type, |
127 | U8* buffer, S32 offset, S32 numbytes); | 127 | U8* buffer, S32 offset, S32 numbytes); |
@@ -130,12 +130,11 @@ public: | |||
130 | 130 | ||
131 | /*virtual*/ bool processRequest(QueuedRequest* req); | 131 | /*virtual*/ bool processRequest(QueuedRequest* req); |
132 | 132 | ||
133 | static void initClass(bool local_is_threaded = TRUE, bool run_always = TRUE); // Setup sLocal | 133 | public: |
134 | static void initClass(bool local_is_threaded = TRUE); // Setup sLocal | ||
134 | static S32 updateClass(U32 ms_elapsed); | 135 | static S32 updateClass(U32 ms_elapsed); |
135 | static void cleanupClass(); // Delete sLocal | 136 | static void cleanupClass(); // Delete sLocal |
136 | 137 | static void setDataPath(const std::string& path) { sDataPath = path; } | |
137 | public: | ||
138 | static LLVFSThread* sLocal; // Default worker thread | ||
139 | }; | 138 | }; |
140 | 139 | ||
141 | //============================================================================ | 140 | //============================================================================ |