ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/gvpe/src/util.C
(Generate patch)

Comparing gvpe/src/util.C (file contents):
Revision 1.2 by pcg, Fri Mar 21 23:17:01 2003 UTC vs.
Revision 1.3 by pcg, Fri Mar 28 04:05:10 2003 UTC

1/* 1/*
2 util.C -- process management and other utility functions 2 util.C -- process management and other utility functions
3 3
4 Most of these are taken from tinc, see the AUTHORS file. 4 Some of these are taken from tinc, see the AUTHORS file.
5 5
6 This program is free software; you can redistribute it and/or modify 6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by 7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or 8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version. 9 (at your option) any later version.
140 140
141 if (!confbase) 141 if (!confbase)
142 asprintf (&confbase, "%s/vpe", CONFDIR); 142 asprintf (&confbase, "%s/vpe", CONFDIR);
143} 143}
144 144
145sockinfo::operator const char *()
146{
147 static char hostport[15 + 1 + 5 + 1];
148 in_addr ia = { host };
149
150 sprintf (hostport, "%.15s:%d", inet_ntoa (ia), ntohs (port) & 0xffff);
151
152 return hostport;
153}
154

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines