// ===========================================================================
class Fence
- : public LightRefBase<Fence>, public Flattenable
+ : public LightRefBase<Fence>, public Flattenable<Fence>
{
public:
static const sp<Fence> NO_FENCE;
// waitForever is a convenience function for waiting forever for a fence to
// signal (just like wait(TIMEOUT_NEVER)), but issuing an error to the
// system log and fence state to the kernel log if the wait lasts longer
- // than warningTimeout. The logname argument should be a string identifying
+ // than a warning timeout.
+ // The logname argument should be a string identifying
// the caller and will be included in the log message.
- status_t waitForever(unsigned int warningTimeout, const char* logname);
+ status_t waitForever(const char* logname);
// merge combines two Fence objects, creating a new Fence object that
// becomes signaled when both f1 and f2 are signaled (even if f1 or f2 is
// Flattenable interface
size_t getFlattenedSize() const;
size_t getFdCount() const;
- status_t flatten(void* buffer, size_t size,
- int fds[], size_t count) const;
- status_t unflatten(void const* buffer, size_t size,
- int fds[], size_t count);
+ status_t flatten(void*& buffer, size_t& size, int*& fds, size_t& count) const;
+ status_t unflatten(void const*& buffer, size_t& size, int const*& fds, size_t& count);
private:
// Only allow instantiation using ref counting.
friend class LightRefBase<Fence>;
- virtual ~Fence();
+ ~Fence();
// Disallow copying
Fence(const Fence& rhs);