pico2024 format string 0

แชร์
ฝัง
  • เผยแพร่เมื่อ 29 ต.ค. 2024

ความคิดเห็น • 6

  • @PhamThanh-s2q
    @PhamThanh-s2q หลายเดือนก่อน

    Sorry, but i don't know why printf(choice1) doesn't have format string error?

    • @carlislemc
      @carlislemc  หลายเดือนก่อน +1

      Because you aren't allowed to put in an arbitrary string, but only one on the menu.

  • @atharvrevankar379
    @atharvrevankar379 2 หลายเดือนก่อน

    I didnt really understand the working im kinda like a noob in this but could you explain how it works ?like my only doubt is why it segfaults for Cla%sic_Che%s%steak and not for any other combination of %s

    • @carlislemc
      @carlislemc  2 หลายเดือนก่อน

      You might want to read more about format string specifiers, e.g. cplusplus.com/reference/cstdio/printf/.

  • @satyamraj17
    @satyamraj17 2 หลายเดือนก่อน

    Okay, after seeing this video, I think it was straightforward.
    When I was trying, I got to the point that I had to give some input greater than that mentioned (2*BUF_SIZE). I overlooked the %114d in one of the choices. I wrote Breakf@st_Burger 5 times in the input without spaces. I did get the message "There is no such burger yet", but I also got the flag. Is it because of some overflow?

    • @carlislemc
      @carlislemc  2 หลายเดือนก่อน

      This problem prints the flag if you make it crash for any reason.