From 04223d27403bf4f46774c7cc86119d55328d418a Mon Sep 17 00:00:00 2001 From: Tudor Bosman Date: Tue, 5 Feb 2013 13:12:26 -0800 Subject: [PATCH] fix typos Test Plan: async_io_test Reviewed By: lucian@fb.com FB internal diff: D699175 --- folly/Exception.h | 2 +- folly/experimental/io/AsyncIO.h | 4 ++-- folly/experimental/io/test/AsyncIOTest.cpp | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/folly/Exception.h b/folly/Exception.h index 5820f68b..5549c4bd 100644 --- a/folly/Exception.h +++ b/folly/Exception.h @@ -54,7 +54,7 @@ inline void checkKernelError(ssize_t ret, const char* msg) { } } -// Check a traditional Uinx return code (-1 and sets errno on error), throw +// Check a traditional Unix return code (-1 and sets errno on error), throw // on error. inline void checkUnixError(ssize_t ret, const char* msg) { if (UNLIKELY(ret == -1)) { diff --git a/folly/experimental/io/AsyncIO.h b/folly/experimental/io/AsyncIO.h index 81ed94dc..4abd12e4 100644 --- a/folly/experimental/io/AsyncIO.h +++ b/folly/experimental/io/AsyncIO.h @@ -44,7 +44,7 @@ class AsyncIO : private boost::noncopyable { }; /** - * Create an AsyncIO context capacble of holding at most 'capacity' pending + * Create an AsyncIO context capable of holding at most 'capacity' pending * requests at the same time. As requests complete, others can be scheduled, * as long as this limit is not exceeded. * @@ -53,7 +53,7 @@ class AsyncIO : private boost::noncopyable { * * If pollMode is POLLABLE, pollFd() will return a file descriptor that * can be passed to poll / epoll / select and will become readable when - * any IOs on this AioReader have completed. If you do this, you must use + * any IOs on this AsyncIO have completed. If you do this, you must use * pollCompleted() instead of wait() -- do not read from the pollFd() * file descriptor directly. */ diff --git a/folly/experimental/io/test/AsyncIOTest.cpp b/folly/experimental/io/test/AsyncIOTest.cpp index 77595c66..c8601309 100644 --- a/folly/experimental/io/test/AsyncIOTest.cpp +++ b/folly/experimental/io/test/AsyncIOTest.cpp @@ -114,13 +114,13 @@ TemporaryFile::~TemporaryFile() { } } -TemporaryFile thisBinary(6 << 20); // 6MiB +TemporaryFile tempFile(6 << 20); // 6MiB void testReadsSerially(const std::vector& specs, AsyncIO::PollMode pollMode) { AsyncIO aioReader(1, pollMode); AsyncIO::Op op; - int fd = ::open(thisBinary.path().c_str(), O_DIRECT | O_RDONLY); + int fd = ::open(tempFile.path().c_str(), O_DIRECT | O_RDONLY); PCHECK(fd != -1); SCOPE_EXIT { ::close(fd); @@ -147,7 +147,7 @@ void testReadsParallel(const std::vector& specs, std::unique_ptr ops(new AsyncIO::Op[specs.size()]); std::vector> bufs(specs.size()); - int fd = ::open(thisBinary.path().c_str(), O_DIRECT | O_RDONLY); + int fd = ::open(tempFile.path().c_str(), O_DIRECT | O_RDONLY); PCHECK(fd != -1); SCOPE_EXIT { ::close(fd); @@ -269,7 +269,7 @@ TEST(AsyncIO, ManyAsyncDataPollable) { TEST(AsyncIO, NonBlockingWait) { AsyncIO aioReader(1, AsyncIO::NOT_POLLABLE); AsyncIO::Op op; - int fd = ::open(thisBinary.path().c_str(), O_DIRECT | O_RDONLY); + int fd = ::open(tempFile.path().c_str(), O_DIRECT | O_RDONLY); PCHECK(fd != -1); SCOPE_EXIT { ::close(fd); -- 2.34.1