diff options
author | Eugene Tarassov | 2014-06-19 00:54:42 +0000 |
---|---|---|
committer | Eugene Tarassov | 2014-06-19 00:54:42 +0000 |
commit | c85f33f77194f8757afc7f77bad779719dab703c (patch) | |
tree | 90d3749f2204507ebc3ff7b910af828ffb17384e | |
parent | a06365bdc1482978bd456ac54aec3f3364fdb785 (diff) | |
download | org.eclipse.tcf.agent-c85f33f77194f8757afc7f77bad779719dab703c.tar.gz org.eclipse.tcf.agent-c85f33f77194f8757afc7f77bad779719dab703c.tar.xz org.eclipse.tcf.agent-c85f33f77194f8757afc7f77bad779719dab703c.zip |
TCF Agent: code cleanup
-rw-r--r-- | agent/tcf/framework/mdep.c | 6 | ||||
-rw-r--r-- | agent/tcf/services/filesystem.h | 4 |
2 files changed, 6 insertions, 4 deletions
diff --git a/agent/tcf/framework/mdep.c b/agent/tcf/framework/mdep.c index 45b0648b..9e4f87db 100644 --- a/agent/tcf/framework/mdep.c +++ b/agent/tcf/framework/mdep.c @@ -1382,7 +1382,8 @@ void become_daemon(char **args) { if (ReadFile((HANDLE)_get_osfhandle(fdpairs[i*2]), tmpbuf, sizeof tmpbuf, &size, NULL)) { if (write(fdpairs[i*2 + 1], tmpbuf, size) < 0) perror("write"); - } else if (GetLastError() != ERROR_NO_DATA) { + } + else if (GetLastError() != ERROR_NO_DATA) { if (GetLastError() != ERROR_BROKEN_PIPE) { fprintf(stderr, "SetNamedPipeHandleState failed 0x%lx\n", GetLastError()); } @@ -1495,7 +1496,8 @@ void become_daemon(void) { if (rval > 0) { if (write(fdpairs[i*2 + 1], tmpbuf, rval) < 0) perror("write"); - } else { + } + else { if (rval < 0) perror("read"); fdpairs[i*2] = fdpairs[(npairs - 1)*2]; diff --git a/agent/tcf/services/filesystem.h b/agent/tcf/services/filesystem.h index 8ca0139c..3678c2bd 100644 --- a/agent/tcf/services/filesystem.h +++ b/agent/tcf/services/filesystem.h @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2007, 2013 Wind River Systems, Inc. and others. + * Copyright (c) 2007, 2014 Wind River Systems, Inc. and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * and Eclipse Distribution License v1.0 which accompany this distribution. @@ -48,7 +48,7 @@ static const int FSERR_E2BIG = 0x10009, FSERR_ENOEXEC = 0x1000a, FSERR_EBADF = 0x1000b, - FSERR_ECHILD = 0x1000c, + FSERR_ECHILD = 0x1000c, FSERR_EAGAIN = 0x1000d, FSERR_ENOMEM = 0x1000e, FSERR_EFAULT = 0x1000f, |