Skip to content

Commit

Permalink
Getting rid of compiler warnings
Browse files Browse the repository at this point in the history
Signed-off-by: Rodrigo Tobar <[email protected]>
  • Loading branch information
rtobar authored and abh3 committed Nov 21, 2017
1 parent 9f0b94c commit a83bfc1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/bbcp_Protocol.C
Original file line number Diff line number Diff line change
Expand Up @@ -944,7 +944,7 @@ void bbcp_Protocol::putCSV(char *Host, char *csFn, char *csVal, int csVsz)
{ //1234567890123
struct iovec iov[] = {{(char *)"Checksum: ", 10},
{bbcp_Cfg.csName,strlen(bbcp_Cfg.csName)},
{(char *)" ", 1}, {csVal, csVsz},
{(char *)" ", 1}, {csVal, static_cast<std::size_t>(csVsz)},
{(char *)" ", 1}, {Host, strlen(Host)},
{(char *)":", 1}, {csFn, strlen(csFn)},
{(char *)"\n",1}};
Expand Down
4 changes: 3 additions & 1 deletion src/bbcp_Pthread.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@
#include <time.h>
#include <semaphore.h>

#include <exception>

class bbcp_CondVar
{
public:
Expand Down Expand Up @@ -156,7 +158,7 @@ inline void Wait() {int rc;
bbcp_Semaphore(int semval=1) {if (sem_init(&h_semaphore, 0, semval))
{throw "sem_init() failed", errno;}
}
~bbcp_Semaphore() {if (sem_destroy(&h_semaphore))
~bbcp_Semaphore() throw(std::exception) {if (sem_destroy(&h_semaphore))
{throw "sem_destroy() failed", errno;}
}

Expand Down

0 comments on commit a83bfc1

Please sign in to comment.