~ubuntu-branches/ubuntu/trusty/virtualbox-ose/trusty

« back to all changes in this revision

Viewing changes to src/VBox/Devices/Network/slirp/debug.c

  • Committer: Bazaar Package Importer
  • Author(s): Felix Geyer
  • Date: 2009-12-18 16:44:29 UTC
  • mfrom: (0.3.3 upstream) (0.4.6 squeeze)
  • Revision ID: james.westby@ubuntu.com-20091218164429-jd34ccexpv5na11a
Tags: 3.1.2-dfsg-1ubuntu1
* Merge from Debian unstable (LP: #498219), remaining changes:
  - Disable update action
    - debian/patches/u01-disable-update-action.dpatch
  - VirtualBox should go in Accessories, not in System tools (LP: #288590)
    - debian/virtualbox-ose-qt.files/virtualbox-ose.desktop
  - Add Apport hook
    - debian/virtualbox-ose.files/source_virtualbox-ose.py
    - debian/virtualbox-ose.install
  - Add Launchpad integration
    - debian/control
    - debian/lpi-bug.xpm
    - debian/patches/u02-lp-integration.dpatch
* Fixes the following bugs:
  - Kernel module fails to build with Linux >= 2.6.32 (LP: #474625)
  - X.Org drivers need to be rebuilt against X-Server 1.7 (LP: #495935)
  - The *-source packages try to build the kernel modules even though the
    kernel headers aren't available (LP: #473334)
* Replace *-source packages with transitional packages for *-dkms.
* Adapt u01-disable-update-action.dpatch and u02-lp-integration.dpatch for
  new upstream version.

Show diffs side-by-side

added added

removed removed

Lines of Context:
158
158
void
159
159
mbufstats(PNATState pData)
160
160
{
 
161
#ifndef VBOX_WITH_SLIRP_BSD_MBUF
 
162
    /*
 
163
     * (vvl) this static code can't work with mbuf zone anymore 
 
164
     * @todo: make statistic correct
 
165
     */
 
166
#if 0
161
167
    struct mbuf *m;
162
168
    int i;
163
169
 
177
183
        i++;
178
184
    lprint("  %6d mbufs on used list\n",  i);
179
185
    lprint("  %6d mbufs queued as packets\n\n", if_queued);
 
186
#endif
 
187
#endif
180
188
}
181
189
 
182
190
void
193
201
 
194
202
    QSOCKET_FOREACH(so, so_next, tcp)
195
203
    /* { */
196
 
        n = sprintf(buff, "tcp[%s]", so->so_tcpcb?tcpstates[so->so_tcpcb->t_state]:"NONE");
 
204
        n = RTStrPrintf(buff, sizeof(buff), "tcp[%s]", so->so_tcpcb?tcpstates[so->so_tcpcb->t_state]:"NONE");
197
205
        while (n < 17)
198
206
            buff[n++] = ' ';
199
207
        buff[17] = 0;
207
215
 
208
216
    QSOCKET_FOREACH(so, so_next, udp)
209
217
    /* { */
210
 
        n = sprintf(buff, "udp[%d sec]", (so->so_expire - curtime) / 1000);
 
218
        n = RTStrPrintf(buff, sizeof(buff), "udp[%d sec]", (so->so_expire - curtime) / 1000);
211
219
        while (n < 17)
212
220
            buff[n++] = ' ';
213
221
        buff[17] = 0;
276
284
                "socket(%d) SS_NODREF",so->s);
277
285
    status = getsockname(so->s, &addr, &socklen);
278
286
 
279
 
    if (status != 0 || addr.sa_family != AF_INET)
 
287
    if(status != 0 || addr.sa_family != AF_INET)
280
288
    {
281
289
        return RTStrFormat(pfnOutput, pvArgOutput, NULL, 0,
282
290
                "socket(%d) is invalid(probably closed)",so->s);