| 362 | } |
| 363 | |
| 364 | void incrRefCount(robj *o) { |
| 365 | if (o->refcount < OBJ_FIRST_SPECIAL_REFCOUNT) { |
| 366 | o->refcount++; |
| 367 | } else { |
| 368 | if (o->refcount == OBJ_SHARED_REFCOUNT) { |
| 369 | /* Nothing to do: this refcount is immutable. */ |
| 370 | } else if (o->refcount == OBJ_STATIC_REFCOUNT) { |
| 371 | serverPanic("You tried to retain an object allocated in the stack"); |
| 372 | } |
| 373 | } |
| 374 | } |
| 375 | |
| 376 | void decrRefCount(robj *o) { |
| 377 | if (o->refcount == 1) { |
no outgoing calls
no test coverage detected