diff --git a/doc/source/writing_ryu_app.rst b/doc/source/writing_ryu_app.rst index a4d1830a..c2f71526 100644 --- a/doc/source/writing_ryu_app.rst +++ b/doc/source/writing_ryu_app.rst @@ -67,11 +67,16 @@ the ports. dp = msg.datapath ofp = dp.ofproto ofp_parser = dp.ofproto_parser - + actions = [ofp_parser.OFPActionOutput(ofp.OFPP_FLOOD)] + + data = None + if msg.buffer_id == ofp.OFP_NO_BUFFER + data = msg.data + out = ofp_parser.OFPPacketOut( datapath=dp, buffer_id=msg.buffer_id, in_port=msg.in_port, - actions=actions) + actions=actions, data = data) dp.send_msg(out)