X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=Socket%2FCommunicationPolicy.cc;h=ef0bba51ba8e8e70032d656eb399abb7a11228cb;hb=bd9f9d3fd6fbcff0112a7bf48ab9284da9576b11;hp=8523966ef7895bb97520961962f8ec8bd98ad6be;hpb=c52cd7d87dbb525c1267aad27391b8b7365dbb57;p=senf.git diff --git a/Socket/CommunicationPolicy.cc b/Socket/CommunicationPolicy.cc index 8523966..ef0bba5 100644 --- a/Socket/CommunicationPolicy.cc +++ b/Socket/CommunicationPolicy.cc @@ -1,9 +1,9 @@ // $Id$ // -// Copyright (C) 2006 -// Fraunhofer Institut fuer offene Kommunikationssysteme (FOKUS) -// Kompetenzzentrum fuer Satelitenkommunikation (SatCom) -// Stefan Bund +// Copyright (C) 2006 +// Fraunhofer Institute for Open Communication Systems (FOKUS) +// Competence Center NETwork research (NET), St. Augustin, GERMANY +// Stefan Bund // // This program is free software; you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by @@ -20,7 +20,9 @@ // Free Software Foundation, Inc., // 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -// Definition of non-inline non-template functions +/** \file + \brief CommunicationPolicy non-inline non-template implementation + */ #include "CommunicationPolicy.hh" //#include "CommunicationPolicy.ih" @@ -29,22 +31,22 @@ #include #include #include -#include "Utils/Exception.hh" +#include "../Utils/Exception.hh" #include "ServerSocketHandle.hh" //#include "CommunicationPolicy.mpp" #define prefix_ ///////////////////////////////cc.p//////////////////////////////////////// -prefix_ void satcom::lib::ConnectedCommunicationPolicy::listen(FileHandle handle, - unsigned backlog) +prefix_ void senf::ConnectedCommunicationPolicy::do_listen(FileHandle handle, + unsigned backlog) { ::listen(handle.fd(),backlog); } -prefix_ int satcom::lib::ConnectedCommunicationPolicy::do_accept(FileHandle handle, - struct sockaddr * addr, - unsigned len) +prefix_ int senf::ConnectedCommunicationPolicy::do_accept(FileHandle handle, + struct sockaddr * addr, + unsigned len) { int rv = -1; do { @@ -53,11 +55,10 @@ prefix_ int satcom::lib::ConnectedCommunicationPolicy::do_accept(FileHandle hand switch (errno) { case EWOULDBLOCK: return -1; - break; case EINTR: break; default: - throw SystemException(errno); + SENF_THROW_SYSTEM_EXCEPTION("ConnectedCommunicationPolicy::do_accept failed."); } } while (rv<0); return rv; @@ -70,5 +71,10 @@ prefix_ int satcom::lib::ConnectedCommunicationPolicy::do_accept(FileHandle hand // Local Variables: // mode: c++ -// c-file-style: "satcom" +// fill-column: 100 +// c-file-style: "senf" +// indent-tabs-mode: nil +// ispell-local-dictionary: "american" +// compile-command: "scons -u test" +// comment-column: 40 // End: