rgw/rgw_formats.cc: fix realloc memory leak

Fix handling of realloc. If realloc() fails it returns NULL, assigning
the return value of realloc() directly to the pointer without checking
for the result will lead to a memory leak in error case.

Use a temporary pointer to hold the result of realloc(). In error case
print error and exit, otherwise assign it to the pointer we want to realloc.

Fix also error checks for malloc to fail as soon as malloc fails and
don't try to run realloc again after failed malloc.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
msg/async/Event.cc: use static_cast instead of c-style cast

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
test/libradosstriper/striping.cc: fix wrong indentation

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
libradosstriper/striping.cc: fix strdup memory leaks

Fix memory leak caused by using std::string to hold result
of strdup call returned from getObjName().

Fix for Coverity issues:

CID 1221525 (#1 of 1): Resource leak (RESOURCE_LEAK)
 leaked_storage: Failing to save or free storage allocated by
 this->getObjName(soid, 0UL) leaks it.

CID 1221526 (1-3 of 3): Resource leak (RESOURCE_LEAK)
 leaked_storage: Failing to save or free storage allocated by
 this->getObjName(soid, *) leaks it.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
test/librbd/fsx.c: fix indentation (NESTING_INDENT_MISMATCH)

Fix indentation to the same as the original fsx.c .

Fix for Coverity issue:

CID 1219473 (#1-2 of 2): Nesting level does not match indentation
(NESTING_INDENT_MISMATCH)
 uncle: This statement is indented to column 25, as if it were
 nested within the preceding parent statement, but it is not.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>