net: Fix a couple of large TCP segment issues

This pull request contains two commits I made to correct issues that were reported by mbed user S K UCI in this forum posting: http://mbed.org/forum/mbed/topic/4354/?page=2#comment-22657  This test is a very good stress test of the mbed networking stack.  It might be good to have it added to the official mbed test suite for the networking stack.  In particular it sends a bunch of different sized buffers down to the stack quite quickly.  This exercises the lwIP code which will link multiple pbufs into a single segment when timing allows.  It was this linking of various sized pbufs into the same TCP segment which exposed both of the bugs fixed in this pull request.

Edit: I forgot to mention that I did test these fixes by running a number of local TCP/UDP tests that people have given me to reproduce other issues in the past.  In addition, I ran the official mbed NET_1 test too.