On Thu, Oct 26, 2006 at 08:37:06AM +0100, Julian Lyndon-Smith wrote: > Any more thoughts on this ? > ;)
yes i have a fix that i will commit today. it is a bit bigger than what i wanted because the original code might overwrite one byte after the buffer, and has an ambiguity on the way strings containing a '\0' are handled - basically, get_input() uses \r\n as an end-of-line marker, but other code takes a \0 as end of line cheers luigi > Julian > > Luigi Rizzo wrote: > > On Wed, Oct 25, 2006 at 05:36:24PM +0100, Julian Lyndon-Smith wrote: > >> just come across a strange problem, and wanted some advice: I was > >> passing a string of commands to the manager command API. This string is > >> 449 bytes long. > >> > >> under 1.4, things seemed to work just fine. > >> > >> under trunk, I get a WARNING[32203]: manager.c:1916 get_input: Dumping > >> long line with no return from 127.0.0.1 > >> > >> I've had a look at the source, and in manager.c get_input there are two > >> blocks of code that seem to be swapped around. I don't know if that was > >> deliberate or not. > > > > 256 seems to be the max line length. > > > > But you are right that there must be something wrong with the code, > > both before and after the change. > > Let me think about it a bit. > > > > cheers > > luigi > > > >> What is the max string that can be passed to the manager API call > >> "command" ? is it 256 ? or is it broken into 256 byte chunks ? > >> > >> I've highlighted the differences in http://pastebin.ca/221252 > >> > >> The checkin that changed the order of the blocks was 45572 - can anyone > >> shed any light on this ? > >> > >> Julian > >> _______________________________________________ > >> --Bandwidth and Colocation provided by Easynews.com -- > >> > >> asterisk-dev mailing list > >> To UNSUBSCRIBE or update options visit: > >> http://lists.digium.com/mailman/listinfo/asterisk-dev > > _______________________________________________ > > --Bandwidth and Colocation provided by Easynews.com -- > > > > asterisk-dev mailing list > > To UNSUBSCRIBE or update options visit: > > http://lists.digium.com/mailman/listinfo/asterisk-dev > > > > > > _______________________________________________ > --Bandwidth and Colocation provided by Easynews.com -- > > asterisk-dev mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-dev _______________________________________________ --Bandwidth and Colocation provided by Easynews.com -- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
