{"action":"created","issue":{"url":"https://api.github.com/repos/trema/routing_switch/issues/4","labels_url":"https://api.github.com/repos/trema/routing_switch/issues/4/labels{/name}","comments_url":"https://api.github.com/repos/trema/routing_switch/issues/4/comments","events_url":"https://api.github.com/repos/trema/routing_switch/issues/4/events","html_url":"https://github.com/trema/routing_switch/issues/4","id":119861865,"number":4,"title":"パケットの送信元と宛先が同一のときにプログラムが停止してしまう不具合","user":{"login":"yamatchan","id":7971850,"avatar_url":"https://avatars.githubusercontent.com/u/7971850?v=3","gravatar_id":"","url":"https://api.github.com/users/yamatchan","html_url":"https://github.com/yamatchan","followers_url":"https://api.github.com/users/yamatchan/followers","following_url":"https://api.github.com/users/yamatchan/following{/other_user}","gists_url":"https://api.github.com/users/yamatchan/gists{/gist_id}","starred_url":"https://api.github.com/users/yamatchan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yamatchan/subscriptions","organizations_url":"https://api.github.com/users/yamatchan/orgs","repos_url":"https://api.github.com/users/yamatchan/repos","events_url":"https://api.github.com/users/yamatchan/events{/privacy}","received_events_url":"https://api.github.com/users/yamatchan/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/trema/routing_switch/labels/bug","name":"bug","color":"fc2929"}],"state":"open","locked":false,"assignee":{"login":"yasuhito","id":8810,"avatar_url":"https://avatars.githubusercontent.com/u/8810?v=3","gravatar_id":"","url":"https://api.github.com/users/yasuhito","html_url":"https://github.com/yasuhito","followers_url":"https://api.github.com/users/yasuhito/followers","following_url":"https://api.github.com/users/yasuhito/following{/other_user}","gists_url":"https://api.github.com/users/yasuhito/gists{/gist_id}","starred_url":"https://api.github.com/users/yasuhito/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yasuhito/subscriptions","organizations_url":"https://api.github.com/users/yasuhito/orgs","repos_url":"https://api.github.com/users/yasuhito/repos","events_url":"https://api.github.com/users/yasuhito/events{/privacy}","received_events_url":"https://api.github.com/users/yasuhito/received_events","type":"User","site_admin":false},"milestone":null,"comments":5,"created_at":"2015-12-02T03:52:07Z","updated_at":"2015-12-03T03:10:54Z","closed_at":null,"body":"以下のコードを実行した時に，``lib/path_manager.rb:18``の``#send_packet_out``の``datapath_id``に``nil``が指定されてしまいプログラムが途中で停止してしまう不具合がありました．\r\nパケットの送信元と宛先が同一の時に生じる不具合だと思われます．\r\n\r\n```\r\n$ bin/trema run lib/routing_switch.rb -c trema.conf\r\n$ bin/trema send_packet -s host1 -d host1\r\n```"},"comment":{"url":"https://api.github.com/repos/trema/routing_switch/issues/comments/161502995","html_url":"https://github.com/trema/routing_switch/issues/4#issuecomment-161502995","issue_url":"https://api.github.com/repos/trema/routing_switch/issues/4","id":161502995,"user":{"login":"yasuhito","id":8810,"avatar_url":"https://avatars.githubusercontent.com/u/8810?v=3","gravatar_id":"","url":"https://api.github.com/users/yasuhito","html_url":"https://github.com/yasuhito","followers_url":"https://api.github.com/users/yasuhito/followers","following_url":"https://api.github.com/users/yasuhito/following{/other_user}","gists_url":"https://api.github.com/users/yasuhito/gists{/gist_id}","starred_url":"https://api.github.com/users/yasuhito/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yasuhito/subscriptions","organizations_url":"https://api.github.com/users/yasuhito/orgs","repos_url":"https://api.github.com/users/yasuhito/repos","events_url":"https://api.github.com/users/yasuhito/events{/privacy}","received_events_url":"https://api.github.com/users/yasuhito/received_events","type":"User","site_admin":false},"created_at":"2015-12-03T03:10:54Z","updated_at":"2015-12-03T03:10:54Z","body":"ですね! ふつうはループバックになりますが、Trema の send_packet はいったん送ってしまいます。\r\n\r\nループバックっぽくするために、send_packet の望ましい挙動としては、--source と --dest が同じだったら何もパケットは送らず、show_stats で見れるカウンタを一つインクリメントするのがいいのかな? と思いました。どう思いますか?"}}