Changeset 87923 in vbox
- Timestamp:
- Mar 2, 2021 7:58:53 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxIntnetPcap/VBoxIntnetPcap.cpp
r87910 r87923 36 36 IntNetIf g_net; 37 37 PRTSTREAM g_pStrmOut; 38 bool g_fPacketBuffered; 38 39 uint64_t g_u64Count; 39 40 size_t g_cbSnapLen; … … 45 46 { "--network", 'n', RTGETOPT_REQ_STRING }, 46 47 { "--snaplen", 's', RTGETOPT_REQ_UINT32 }, 48 { "--packet-buffered", 'U', RTGETOPT_REQ_NOTHING }, 47 49 { "--write", 'w', RTGETOPT_REQ_STRING }, 48 50 }; … … 100 102 "--snaplen must be greater than zero"); 101 103 g_cbSnapLen = Val.u32; 104 break; 105 106 case 'U': /* --packet-buffered */ 107 g_fPacketBuffered = true; 102 108 break; 103 109 … … 191 197 return RTMsgErrorExit(RTEXITCODE_FAILURE, 192 198 "write: %Rrf", rc); 199 if (g_fPacketBuffered) 200 RTStrmFlush(g_pStrmOut); 193 201 194 202 g_net.ifPump(); … … 224 232 } 225 233 234 if (g_fPacketBuffered) 235 RTStrmFlush(g_pStrmOut); 236 226 237 checkCaptureLimit(); 227 238 }
Note:
See TracChangeset
for help on using the changeset viewer.