heapdump_vmo/
lib.rs

1// Copyright 2023 The Fuchsia Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5use thiserror::Error;
6
7pub mod allocations_table_v1;
8mod memory_mapped_vmo;
9pub mod resources_table_v1;
10pub mod stack_trace_compression;
11
12#[derive(Debug, Eq, Error, PartialEq)]
13pub enum Error {
14    #[error("The provided memory region is too small")]
15    BufferTooSmall,
16    #[error("The provided memory region is too big")]
17    BufferTooBig,
18    #[error("Operation failed due to lack of space")]
19    OutOfSpace,
20    #[error("Operation failed because the provided input is not valid")]
21    InvalidInput,
22    #[error("System call failed: {}", .0)]
23    SyscallFailed(#[from] zx::Status),
24}