"(null)" at the end of frame dumps




5 years ago
5 years ago


(Reporter: mats, Unassigned)


Firefox Tracking Flags

(Not tracked)




5 years ago
There seems to be a "(null)" at the end of frame dumps:

HTMLScroll(div)(-1)@7f02a64a1020 next=7f02a64a1930 {300,120,21000,7320} [state=0000000000084409] [content=7f02a559de80] [sc=7f02a64104a8]<
  Block(div)(-1)@7f02a64a15f0 {0,0,18000,6000} [state=0000100000d04200] [content=7f02a559de80] [sc=7f02a5511d60:-moz-scrolled-content]<
    line 7f02a64a18f0: count=1 state=inline,clean,prevmarginclean,not impacted,not wrapped,before:nobr,after:nobr[0x100] {3000,3000,0,0} vis-overflow=3000,3360,0,0 scr-overflow=3000,3360,0,0 <
      Text(0)""@7f02a64a1880 {3000,3360,0,0} [state=0000000020404000] [content=7f02a6413d70] [sc=7f02a64a1310:-moz-non-element,parent=7f02a64104a8] [run=7f02a559f080][0,0,T] 
I saw this in some frame dumps posted by others, but haven't been able to see it locally so far.
I think it might be because of the default argument 'const char* aPrefix = ""', it doesn't seem like my gdb handles it correctly if I omit that argument. It seemed to take the prefix to be "PresShell" in one instance just now for me.

Maybe we could make it an int again, or just make it required.

Comment 3

5 years ago
The above dump was from adding List(stdout, 0) in a C++ file (in a method where 'this'
is a frame).  Can you reproduce it with that?
Well that explains it, the second argument is now a const char*, and in nsContainerFrame::List we end by outputting the const char followed by '>'. I guess it usually works most of the time because we just add the prefix const char* to a nsCString, I'm assuming that does nothing. Whereas printf("%s", null) will output null. I guess we can special case a null string to be the empty string there, and anywhere else that might need it.

Comment 5

5 years ago
He, yeah, I realized my mistake as I went to bed last night.  Sorry, it was late...
Last Resolved: 5 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.