Re: [Discuss-gnuradio] GUI problems with 3.7

2013-06-22 Thread Tom Rondeau
On Sat, Jun 22, 2013 at 8:48 AM, Sylvain Munaut <246...@gmail.com> wrote: > Hi, > >>> Huh ... but strcmp will stop comparing at the end of any of the two >>> strings anyway. >> >> No, that's not true. If that were the case then string "abc" would be >> equal to string "ab", and strcmp knows that th

Re: [Discuss-gnuradio] GUI problems with 3.7

2013-06-22 Thread Sylvain Munaut
Hi, >> Huh ... but strcmp will stop comparing at the end of any of the two >> strings anyway. > > No, that's not true. If that were the case then string "abc" would be > equal to string "ab", and strcmp knows that they are different (I > tested this to be sure; it returns 99, while strcmp("abc", "

Re: [Discuss-gnuradio] GUI problems with 3.7

2013-06-22 Thread Tom Rondeau
On Sat, Jun 22, 2013 at 4:50 AM, Sylvain Munaut <246...@gmail.com> wrote: >> In this case, I /know/ that string >> b is properly terminated (because I wrote it into the code). So I use >> the length of b to compare with a and l = strlen(b). There are other >> ways, too, but this was the most unobtr

Re: [Discuss-gnuradio] GUI problems with 3.7

2013-06-22 Thread Sylvain Munaut
> In this case, I /know/ that string > b is properly terminated (because I wrote it into the code). So I use > the length of b to compare with a and l = strlen(b). There are other > ways, too, but this was the most unobtrusive way to handle this case. Huh ... but strcmp will stop comparing at the

Re: [Discuss-gnuradio] GUI problems with 3.7

2013-06-21 Thread Tom Rondeau
On Fri, Jun 21, 2013 at 4:11 PM, Marcus D. Leech wrote: >> On Fri, Jun 21, 2013 at 3:39 PM, Tom Rondeau wrote: >>> >>> On Fri, Jun 21, 2013 at 12:41 PM, Marcus D. Leech >>> wrote: There are safe uses for unconstrained string functions. Just, well, not very many... -- >>>

Re: [Discuss-gnuradio] GUI problems with 3.7

2013-06-21 Thread Marcus D. Leech
On Fri, Jun 21, 2013 at 3:39 PM, Tom Rondeau wrote: On Fri, Jun 21, 2013 at 12:41 PM, Marcus D. Leech wrote: There are safe uses for unconstrained string functions. Just, well, not very many... -- Marcus Leech No. Never, ever, ever is it ok. I say this using a strlen call now... (but it's a

Re: [Discuss-gnuradio] GUI problems with 3.7

2013-06-21 Thread Nathan West
On Fri, Jun 21, 2013 at 3:39 PM, Tom Rondeau wrote: > > On Fri, Jun 21, 2013 at 12:41 PM, Marcus D. Leech wrote: > > There are safe uses for unconstrained string functions. Just, well, not > > very many... > > > > -- > > Marcus Leech > > No. Never, ever, ever is it ok. I say this using a strlen

Re: [Discuss-gnuradio] GUI problems with 3.7

2013-06-21 Thread Tom Rondeau
On Fri, Jun 21, 2013 at 12:41 PM, Marcus D. Leech wrote: > On 06/21/2013 12:38 PM, Tom Rondeau wrote: >> >> First, I think calling it a GUI problem was a red herring. The problem >> was much more fundamental. I traced it down to a 'strcmp'. And I am >> very put out with whoever used that function

[Discuss-gnuradio] GUI problems with 3.7

2013-06-21 Thread Tom Rondeau
First, I think calling it a GUI problem was a red herring. The problem was much more fundamental. I traced it down to a 'strcmp'. And I am very put out with whoever used that function in the first place. Just testing out the solution now and should have a fix pushed shortly. Tom

Re: [Discuss-gnuradio] GUI problems with 3.7

2013-06-21 Thread Marcus D. Leech
On 06/21/2013 12:38 PM, Tom Rondeau wrote: First, I think calling it a GUI problem was a red herring. The problem was much more fundamental. I traced it down to a 'strcmp'. And I am very put out with whoever used that function in the first place. Just testing out the solution now and should have