X-Git-Url: https://git.llucax.com/z.facultad/75.74/practicos.git/blobdiff_plain/918a7b42017533f6f18edc8735d6d82a5494f055..1a2bb56c4c44080e941e6a7dc2420a404bceba5b:/practicas/pipi/src/ipout.cpp?ds=sidebyside diff --git a/practicas/pipi/src/ipout.cpp b/practicas/pipi/src/ipout.cpp index c98c4b5..dea18de 100644 --- a/practicas/pipi/src/ipout.cpp +++ b/practicas/pipi/src/ipout.cpp @@ -78,7 +78,7 @@ bool IPOut::send(IPHeader iph, std::string data) throw (std::runtime_error) iph2.do_checksum(); std::string buf((char*) &iph2, sizeof(IPHeader)); buf += data.substr(i * max_payload, max_payload); -#ifdef DEBUG +#ifdef DEBUG_IP std::cout << "IPOut::send (" << ip << "): Fragmento " << i << " => IPHeader: " << iph2 << "\n"; std::string tmp = data.substr(i * max_payload, max_payload); @@ -97,9 +97,9 @@ void IPOut::forward_loop() { std::string buf = forward_que.receive(); IPHeader iph(buf); -#ifdef DEBUG +#ifdef DEBUG_IP std::cout << "IPOut::forward_loop (" << ip << "): A forwardear (id " - << iph.id << ")\n"; + << iph.id << ", offset " << iph.offset << ")\n"; #endif send(iph, buf.substr(iph.header_len())); }