<div dir="ltr"><div><div><div><div>Hello everyone,<br><br></div>I am using the following code to get hold of the queue object inside the forwarding strategy, OnData(....) function.<br><br>Ptr<NetDeviceFace> netDeviceFace = DynamicCast<NetDeviceFace> (inFace);<br>if (netDeviceFace == NULL) {  }<br>Ptr<NetDevice> nd = netDeviceFace->GetNetDevice ();<br>if (nd == NULL) {  }<br>PointerValue txQueueAttribute;<br>nd->GetAttribute ("TxQueue", txQueueAttribute);<br>Ptr<ns3::Queue> txQueue = txQueueAttribute.Get<ns3::Queue> ();<br>if (txQueue == 0) {    }<br><br></div>But I am getting a segmentation fault SIGSEV error while fetching the NetDevice object and the following errors for accessing queue.<br><br>../src/ndnSIM/model/fw/ndn-forwarding-strategy.cc:238:3: error: ‘PointerValue’ was not declared in this scope<br>    PointerValue txQueueAttribute;<br>   ^<br>../src/ndnSIM/model/fw/ndn-forwarding-strategy.cc:239:32: error: ‘txQueueAttribute’ was not declared in this scope<br>   nd->GetAttribute ("TxQueue", txQueueAttribute);<br>                                ^<br>../src/ndnSIM/model/fw/ndn-forwarding-strategy.cc:243:50: error: expected primary-expression before ‘>’ token<br>   Ptr<Queue> txQueue = txQueueAttribute.Get<Queue> ();<br>                                                  ^<br>../src/ndnSIM/model/fw/ndn-forwarding-strategy.cc:243:53: error: expected primary-expression before ‘)’ token<br>   Ptr<Queue> txQueue = txQueueAttribute.Get<Queue> ();<br><br><br></div>Can you please point me out where I am going wrong.<br><br><br></div><b>Thanks & Regards,</b><br><b style="font-size:12.8px">Ayush Agarwal<br></b><div style="font-size:12.8px"><b>Reseach Scholar, Computer Science<br></b></div><b style="font-size:12.8px">National Institute of Technology, Karnataka<br>Surathkal, India</b><br></div>