]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rados: remove unused "check_stdio" parameter
authorDan Mick <dmick@danceorelse.org>
Thu, 24 Jan 2013 21:38:25 +0000 (13:38 -0800)
committerDan Mick <dan.mick@inktank.com>
Tue, 5 Mar 2013 23:41:18 +0000 (15:41 -0800)
Signed-off-by: Dan Mick <dan.mick@inktank.com>
(cherry picked from commit bb860e49a7faeaf552538a9492ef0ba738c99760)

src/rados.cc

index 4bbfaed8650ad0184ded647b3d4cbb2420d86ecc..3a097feb20d277c88ae77d4f7bbba89d6a21f9ce 100644 (file)
@@ -174,7 +174,7 @@ static int do_get(IoCtx& io_ctx, const char *objname, const char *outfile, unsig
   string oid(objname);
 
   int fd;
-  if (check_stdio && strcmp(outfile, "-") == 0) {
+  if (strcmp(outfile, "-") == 0) {
     fd = 1;
   } else {
     fd = TEMP_FAILURE_RETRY(::open(outfile, O_WRONLY|O_CREAT|O_TRUNC, 0644));
@@ -202,7 +202,7 @@ static int do_get(IoCtx& io_ctx, const char *objname, const char *outfile, unsig
     offset += outdata.length();
   }
 
-  if (!check_stdio)
+  if (fd != 1)
     TEMP_FAILURE_RETRY(::close(fd));
   return 0;
 }
@@ -339,7 +339,7 @@ static int do_put(IoCtx& io_ctx, const char *objname, const char *infile, int op
   string oid(objname);
   bufferlist indata;
   bool stdio = false;
-  if (check_stdio && strcmp(infile, "-") == 0)
+  if (strcmp(infile, "-") == 0)
     stdio = true;
 
   int ret;