Commit bd79d63dffdee25459e06cf9327eab957767863c

Authored by Hayk
1 parent 2721de2b

Tweak formatting of bveldhoen pull request

CMakeLists.txt
... ... @@ -3,7 +3,7 @@ project(redox)
3 3  
4 4 set(REDOX_VERSION_MAJOR 0)
5 5 set(REDOX_VERSION_MINOR 2)
6   -set(REDOX_VERSION_PATCH 2)
  6 +set(REDOX_VERSION_PATCH 3)
7 7 set(REDOX_VERSION_STRING ${REDOX_VERSION_MAJOR}.${REDOX_VERSION_MINOR}.${REDOX_VERSION_PATCH})
8 8  
9 9 option(lib "Build Redox as a dynamic library." ON)
... ... @@ -154,12 +154,12 @@ endif()
154 154  
155 155 set(CMAKE_INSTALL_PREFIX /usr/)
156 156  
157   -MESSAGE ("CMAKE_SIZEOF_VOID_P: ${CMAKE_SIZEOF_VOID_P}")
  157 +# Check if it is a 64 bit system
158 158 if(CMAKE_SIZEOF_VOID_P EQUAL 8 AND NOT LIB_SUFFIX)
159 159 set(LIB_SUFFIX "64")
160 160 endif()
161 161  
162   -# Install the dynamic library to /usr/lib(64)
  162 +# Install the dynamic library to /usr/lib[64]
163 163 install(TARGETS redox DESTINATION lib${LIB_SUFFIX})
164 164  
165 165 # Install the headers into /usr/include/redox
... ...
README.md
... ... @@ -301,9 +301,11 @@ the following commands:
301 301 cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo ..
302 302 make package
303 303  
  304 +NOTE: To build RPM packages, you will need rpmbuild.
  305 +
304 306 ## Contributing
305 307 Redox is in its early stages and I am looking for feedback and contributors to make
306 308 it easier, faster, and more robust. Open issues on GitHub or message me directly.
307 309  
308   -Redox is not currently recommended for production use. It has no support for features like
309   -connection pooling, sentinels, clusters, etc. Feel free to provide them!
  310 +Redox is not currently recommended for production use. It has no support yet for sentinels
  311 +or clusters. Feel free to provide them!
... ...
src/command.cpp
... ... @@ -167,8 +167,7 @@ template<class ReplyT>
167 167 bool Command<ReplyT>::checkErrorReply() {
168 168  
169 169 if (reply_obj_->type == REDIS_REPLY_ERROR) {
170   - if (0 != reply_obj_->str)
171   - {
  170 + if (reply_obj_->str != 0) {
172 171 last_error_ = reply_obj_->str;
173 172 }
174 173  
... ...
test/test.cpp
... ... @@ -49,9 +49,7 @@ protected:
49 49 rdx.command({"DEL", "redox_test:a"});
50 50 }
51 51  
52   - virtual ~RedoxTest()
53   - {
54   - }
  52 + virtual ~RedoxTest() {}
55 53  
56 54 // CV and counter to wait for async commands to complete
57 55 atomic_int cmd_count = {0};
... ... @@ -153,13 +151,11 @@ protected:
153 151 // Core unit tests - asynchronous
154 152 // -------------------------------------------
155 153  
156   -TEST_F(RedoxTest, TestConnection)
157   -{
  154 +TEST_F(RedoxTest, TestConnection) {
158 155 EXPECT_TRUE(rdx.connect("localhost", 6379));
159 156 }
160 157  
161   -TEST_F(RedoxTest, TestConnectionFailure)
162   -{
  158 +TEST_F(RedoxTest, TestConnectionFailure) {
163 159 EXPECT_FALSE(rdx.connect("localhost", 6380));
164 160 }
165 161  
... ...