vfs: check userland buffers before reading them.
[haiku.git] / src / kits / debugger / model / SemaphoreInfo.cpp
blob8d7eddd951204d582cdde641dfe01077f7ca41db
1 /*
2 * Copyright 2013, Rene Gollent, rene@gollent.com.
3 * Distributed under the terms of the MIT License.
4 */
7 #include "SemaphoreInfo.h"
10 SemaphoreInfo::SemaphoreInfo()
12 fTeam(-1),
13 fSemaphore(-1),
14 fName(),
15 fCount(0),
16 fLatestHolder(-1)
21 SemaphoreInfo::SemaphoreInfo(const SemaphoreInfo &other)
23 fTeam(other.fTeam),
24 fSemaphore(other.fSemaphore),
25 fName(other.fName),
26 fCount(other.fCount),
27 fLatestHolder(other.fLatestHolder)
32 SemaphoreInfo::SemaphoreInfo(team_id team, sem_id semaphore,
33 const BString& name, int32 count, thread_id latestHolder)
35 fTeam(team),
36 fSemaphore(semaphore),
37 fName(name),
38 fCount(count),
39 fLatestHolder(latestHolder)
44 void
45 SemaphoreInfo::SetTo(team_id team, sem_id semaphore, const BString& name,
46 int32 count, thread_id latestHolder)
48 fTeam = team;
49 fSemaphore = semaphore;
50 fName = name;
51 fCount = count;
52 fLatestHolder = latestHolder;