Skip to content

Commit 96e787c

Browse files
author
Colin Robertson
committed
Fix per Jim Radigan
1 parent dc0bd65 commit 96e787c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/sanitizers/error-global-buffer-overflow.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ helpviewer_keywords: ["global-buffer-overflow error", "AddressSanitizer error gl
99

1010
> Address Sanitizer Error: Global buffer overflow
1111
12-
The compiler generates metadata for any variable in the `.data` or `.bss` sections. These variables have language scope of global or file static. They're allocated in memory before `main()` starts. Global variables in C are treated much differently than in C++. This difference is because of the complex rules for C++ linking.
12+
The compiler generates metadata for any variable in the `.data` or `.bss` sections. These variables have language scope of global or file static. They're allocated in memory before `main()` starts. Global variables in C are treated much differently than in C++. This difference is because of the complex rules for linking C.
1313

1414
In C, a global variable can be declared in several source files, and each definition can have different types. The compiler can't see all the possible definitions at once, but the linker can. For C, the linker defaults to selecting the largest-sized variable out of all the different declarations.
1515

0 commit comments

Comments
 (0)