summaryrefslogtreecommitdiff
path: root/comm
diff options
context:
space:
mode:
authorchatty1994-05-10 09:49:04 +0000
committerchatty1994-05-10 09:49:04 +0000
commit2d44f1c235029240150361f99c2f349eed62afc4 (patch)
treeab47f43fa599f0cbe33834d3906dfec53ef0a4b1 /comm
parent15b4b9c21f1a58aafb7c5d80b1c986783663ddd7 (diff)
downloadivy-league-2d44f1c235029240150361f99c2f349eed62afc4.zip
ivy-league-2d44f1c235029240150361f99c2f349eed62afc4.tar.gz
ivy-league-2d44f1c235029240150361f99c2f349eed62afc4.tar.bz2
ivy-league-2d44f1c235029240150361f99c2f349eed62afc4.tar.xz
Removed useless default impl of virtual functions
Diffstat (limited to 'comm')
-rw-r--r--comm/Address.h23
1 files changed, 11 insertions, 12 deletions
diff --git a/comm/Address.h b/comm/Address.h
index b220339..70df60b 100644
--- a/comm/Address.h
+++ b/comm/Address.h
@@ -31,18 +31,17 @@
#define AF_UNIX AF_UNSPEC
#endif
-
-typedef struct sockaddr SockAddr;
-
-/* this union is useful for adresses returned by system calls */
-
-typedef union {
+union gen_addr {
struct sockaddr sa; // default
#ifdef UNIX_SOCK
struct sockaddr_un su; // unix
#endif
struct sockaddr_in si; // inet
-} GEN_ADDR;
+};
+
+typedef struct sockaddr SockAddr;
+/* this union is useful for adresses returned by system calls */
+typedef union gen_addr GEN_ADDR;
class UchAddress : public CcuSmartData {
@@ -54,10 +53,10 @@ public:
~UchAddress ();
bool IsValid () const { return Valid; }
-virtual int Family (); // AF_UNSPEC, AF_UNIX, AF_INET
-virtual int Length ();
-virtual SockAddr* GetSockAddr ();
-virtual char* StrRepr (char* buf);
+virtual int Family () = 0; // AF_UNSPEC, AF_UNIX, AF_INET
+virtual int Length () = 0;
+virtual SockAddr* GetSockAddr () = 0;
+virtual char* StrRepr (char* buf) = 0;
static UchAddress* Decode (GEN_ADDR*, int);
};
@@ -70,7 +69,7 @@ protected:
public:
UchInetAddress ();
- UchInetAddress (lword, sword = 0); // hostid, port#
+ UchInetAddress (lword, sword); // hostid, port#
UchInetAddress (const char*, sword = 0); // hostname, port#
~UchInetAddress ();