- if (go->neg_router && (go->router & (BIT(0) | BIT(2) | BIT(4)))) {
- PUTCHAR (IPX_ROUTER_PROTOCOL, ucp);
- PUTCHAR (CILEN_PROTOCOL, ucp);
- PUTSHORT (go->router, ucp);
- }
-
- if (go->neg_complete) {
- PUTCHAR (IPX_COMPLETE, ucp);
- PUTCHAR (CILEN_COMPLETE, ucp);
+ if (go->neg_router) {
+ short external = to_external (go->router);
+ if (external != RIP_SAP) {
+ PUTCHAR (IPX_ROUTER_PROTOCOL, ucp);
+ PUTCHAR (CILEN_PROTOCOL, ucp);
+ PUTSHORT (external, ucp);
+ }