--- a/src/helper/yans-wifi-helper.cc Fri Feb 26 09:35:09 2010 -0800
+++ b/src/helper/yans-wifi-helper.cc Fri Feb 26 10:31:26 2010 -0800
@@ -380,7 +380,7 @@
}
void
-YansWifiPhyHelper::EnablePcapInternal (std::string prefix, Ptr<NetDevice> nd, bool promiscuous)
+YansWifiPhyHelper::EnablePcapInternal (std::string prefix, Ptr<NetDevice> nd, bool explicitFilename, bool promiscuous)
{
//
// All of the Pcap enable functions vector through here including the ones
@@ -398,7 +398,15 @@
NS_ABORT_MSG_IF (phy == 0, "YansWifiPhyHelper::EnablePcapInternal(): Phy layer in WifiNetDevice must be set");
PcapHelper pcapHelper;
- std::string filename = pcapHelper.GetFilenameFromDevice (prefix, device);
+ std::string filename;
+ if (explicitFilename)
+ {
+ filename = prefix;
+ }
+ else
+ {
+ filename = pcapHelper.GetFilenameFromDevice (prefix, device);
+ }
Ptr<PcapFileWrapper> file = pcapHelper.CreateFile (filename, "w", m_pcapDlt);