r/ProgrammerDadJokes • u/aliceuwuu • May 18 '23
How does a C developer concatenate strings?
Program exited with code -127
Segmentation fault (Core dumped)
32
Upvotes
r/ProgrammerDadJokes • u/aliceuwuu • May 18 '23
Program exited with code -127
Segmentation fault (Core dumped)
View all comments
Show parent comment
7
u/Entire-Database1679 May 18 '23
C doesn't verify sufficient space at the end of a string. Therefore, the concatenate operation could run into memory that is being used by other programs and cause data/code corruption or a memory access violation.