vfs: check userland buffers before reading them.
[haiku.git] / src / kits / debugger / debug_info / ImageDebugInfoLoadingState.h
blob80897592cfb521e727e2ccb1a5225d2f7e928e2e
1 /*
2 * Copyright 2014, Rene Gollent, rene@gollent.com.
3 * Distributed under the terms of the MIT License.
4 */
5 #ifndef IMAGE_DEBUG_INFO_LOADING_STATE_H
6 #define IMAGE_DEBUG_INFO_LOADING_STATE_H
8 #include <Referenceable.h>
11 class SpecificImageDebugInfoLoadingState;
14 class ImageDebugInfoLoadingState {
15 public:
16 ImageDebugInfoLoadingState();
17 virtual ~ImageDebugInfoLoadingState();
19 bool HasSpecificDebugInfoLoadingState() const;
20 SpecificImageDebugInfoLoadingState*
21 GetSpecificDebugInfoLoadingState() const
22 { return fSpecificInfoLoadingState; }
23 void SetSpecificDebugInfoLoadingState(
24 SpecificImageDebugInfoLoadingState* state);
25 // note: takes over reference of passed
26 // in state object.
27 void ClearSpecificDebugInfoLoadingState();
29 bool UserInputRequired() const;
32 int32 GetSpecificInfoIndex() const
33 { return fSpecificInfoIndex; }
34 void SetSpecificInfoIndex(int32 index);
36 private:
37 BReference<SpecificImageDebugInfoLoadingState>
38 fSpecificInfoLoadingState;
39 int32 fSpecificInfoIndex;
43 #endif // IMAGE_DEBUG_INFO_LOADING_STATE_H