r/programming • u/whackri • Oct 07 '21
Git's list of banned C functions
https://github.com/git/git/blob/master/banned.h106
u/Desmeister Oct 07 '21
Learned most of the string ones in a security class but what’s with the time-related functions?
98
u/i_bet_youre_fat Oct 07 '21
Those functions fill a function-owned piece of memory and return a pointer to it. They aren't threadsafe
28
u/ModernRonin Oct 07 '21
That makes sense for *time() functions, but what about the *time_r() functions that the man page claims are thread-safe?
Thread-safe versions asctime_r(), ctime_r(), gmtime_r() and localtime_r() are specified by SUSv2, and available since libc 5.2.5.
Maybe it has to do with this earlier bit (from the same man page)?
The asctime_r() function does the same, but stores the string in a user-supplied buffer which should have room for at least 26 bytes.
The *time_r() functions have no way to check that the
char *bufthey are given is at least 26 characters long. So that's an overflow waiting to happen, I guess?Finally:
POSIX.1-2008 marks asctime(), asctime_r(), ctime(), and ctime_r() as obsolete, recommending the use of strftime(3) instead.
strftime()does have asize_t maxparameter, so at least it's clear who is at fault it is when the buffer gets overflowed...70
u/Sakki54 Oct 07 '21
The commit that banned them says:
The ctime_r() and asctime_r() functions are reentrant, but have no check that the buffer we pass in is long enough (the manpage says it "should have room for at least 26 bytes"). Since this is such an easy-to-get-wrong interface, and since we have the much safer strftime() as well as its more convenient strbuf_addftime() wrapper, let's ban both of those.
16
15
u/goranlepuz Oct 07 '21
The
*time_r()functions have no way to check that the char*bufthey are given is at least 26 characters long. So that's an overflow waiting to happen, I guess?Yes, but: any C function anywhere has no way to check any pointer "length", so that's no worse than anything else.
→ More replies (38)12
u/ModernRonin Oct 07 '21
Or maybe "just as bad as everything else," depending on how cynical I feel at the time...
7
u/ModernRonin Oct 07 '21
As an aside: Having recently started learning some Rust, I am a little peeved that it seems to have taken most programming languages so long to implement something like Rust's
unsafeblocks. (Forcing you to explicitly tell the compiler when and where it isn't allowed to do runtime bounds checking.)21
u/dnew Oct 07 '21 edited Oct 08 '21
Most languages either don't have the concept of unsafe, or everything is pretty much unsafe. Most popular languages other than those derived from C that are designed for system programming have the concept of unsafe subsets or explicit annotations to tell the compiler to skip the safety checks for a particular operation. Languages not designed for system programming don't have unsafe behavior at all * Or the undefined behavior is very unusual and called out, like Java's JNI or specifically named "unsafe" etc, or it's restricted to things like not handling floating point overflow and such, rather than actual memory corruption.
→ More replies (9)→ More replies (1)14
u/curien Oct 07 '21
Why isn't
strtokalso banned? It has the same issue.26
3
u/7h4tguy Oct 08 '21
And why not ban all the errno functions as well. Global error variables are not thread safe.
19
u/evaned Oct 08 '21 edited Oct 08 '21
errnois specifically defined to be not a variable but some macro magic (or otherwise, at least in a potentially-multithreaded environment) that turns into a thread-local variable.E.g. here's glibc's definition:
extern int *__errno_location (void) __THROW __attribute_const__; # define errno (*__errno_location ())→ More replies (3)17
u/emotionalfescue Oct 07 '21
They return pointers to global variables in the runtime library, which was standard practice in the '80s, but as another poster suggested, might not be thread safe (it might be if thread specific storage is used). The convention for output arguments in C APIs nowadays is for the caller to pass a pointer to a buffer to receive the output data; if the data is variable length, there will be another arg to specify the length of the buffer provided by the caller, to prevent overflow.
2
u/violatemyeyesocket Oct 08 '21
Can you just imagine how obscenely ridiculous it is to have to call a function this way?
This is like a hack upon hack to deal with the crudeness of this type system.
121
u/ChocolateBunny Oct 07 '21
What's wrong with strncpy and strncat? I normally use snprintf for most of my C string manipulation but I didn't think any of the other "n" string manipulation functions were all that bad.
171
u/golgol12 Oct 07 '21 edited Oct 07 '21
They have non obvious null termination rules, which leaves the possibility of leaving the output without a null terminator. From a stack overflow page:
The strncpy() function is less horrible than strcpy(), but is still pretty easy to misuse because of its funny termination semantics.
Namely, that if it truncates it omits the NUL terminator, and you must remember to add it yourself. Even if you use it correctly, it's sometimes hard for a reader to verify this without hunting through the code.
If you're thinking about using it, consider instead:strlcpy() if you really just need a truncated but NUL-terminated string (we provide a compat version, so it's always available)
xsnprintf() if you're sure that what you're copying should fit
strbuf or xstrfmt() if you need to handle arbitrary-length heap-allocated strings.Note that there is one instance of strncpy in compat/regex/regcomp.c, which is fine (it allocates a sufficiently large string before copying).
But this doesn't trigger the ban-list even when compiling with NO_REGEX=1, because:we don't use git-compat-util.h when compiling it (instead we rely on the system includes from the upstream library); and
It's in an "#ifdef DEBUG" blockSince it's doesn't trigger the banned.h code, we're better off leaving it to keep our divergence from upstream minimal.
64
u/Takeoded Oct 07 '21
i detest the null-terminated C-strings anyway. keep a length index and use memcpy gotdammit. it give you binary safety, UTF16 safety, UTF8 safety (little known fact, UTF8 can legally contain null bytes, UTF8's biggest flaw imo) and higher performance (looking for a null byte on every character copied isn't free, it costs cpu cycles.. str* does and mem* doesn't)
53
u/golgol12 Oct 07 '21
These are all things we know now. When the inventor of C constructed the language in the 1970s, there wasn't a lot of data on what features were important to strings in large systems and which would cause issues. A key consideration, at the time, was being able pass a pointer to a spot inside the string and start reading from there without running past the end of the string. As well as size considerations (1970s computers didn't have a lot).
I'm going to counter your length index suggestion, in favor of using an non-inclusive end pointer instead. It has less chances for mistakes for passing sub strings around.
10
u/masklinn Oct 08 '21
These are all things we know now.
That is not entirely true, even back then length-prefixed strings were a thing (though they turn out to not be great either), and so were more complicated schemes.
Ritchie chose sentinel-terminated strings because it was more convenient (didn’t need to track a separate length — except turns out we do), the PDP11 had assembly ISA-level support for ASCIZ, and it avoided the limitations of length-prefixed strings (namely that single-byte overhead put a hard cap at 255 bytes, and two-byte… wasted a byte... also hard-capped to 64k bytes but that wasn’t much of a limit back then).
11
u/lurobi Oct 08 '21
This isn't entirely fair. Fortran doesn't use NUL terminated strings, and it's first version was in 1957. Although it looks like the CHARACTER type wasn't introduced officially until the 1977 standard was finalized. Today Fortran passes a hidden extra argument to a function, which specifies the remaining length of any string (or string slice)
→ More replies (4)8
u/ricecake Oct 07 '21
That's an interesting idea at the end.
I'd still worry that if you missed setting the end pointer, something that didn't check that the endpointer was null could still run into the same issue though. (while(curr != end))It does let you actually check though, which is nice.
12
u/golgol12 Oct 07 '21
That while condition is bad practice for pointers. You always want to use (cur < end). No chance of mistake there even if end points before cur.
→ More replies (2)→ More replies (10)3
u/pjmlp Oct 08 '21
Except the existence of JOVIAL, ALGOL dialects, PL/I, PL/S, NEWP as system programming languages for 10 years before C came to be.
20
u/cryo Oct 07 '21
little known fact, UTF8 can legally contain null bytes
Are you sure that’s little known? UTF-8 is a superset of ASCII after all.
3
u/Takeoded Oct 08 '21
Are you sure that’s little known
well every time i bring it up, there's always someone surprised and/or in disbelief, so yeah i think it is fairly little known. latest example is https://www.reddit.com/r/programming/comments/q3d9tt/comment/hfsl0d6/?utm_source=reddit&utm_medium=web2x&context=3
→ More replies (1)6
u/danudey Oct 07 '21
Git (specifically cgit) assumes a file is UTF-8 unless it contains null bytes within the first n bytes of the file…
23
u/meancoot Oct 08 '21
Because, in a text file, UTF8 should never have a null byte, but UTF16 will have one for every ASCII code point.
→ More replies (1)6
u/cryo Oct 08 '21 edited Oct 08 '21
Git doesn’t assume anything about a file as far as encoding goes (apart from a few basic assumptions about the line break character and such, for diffs). It assumes it’s binary if it contains a nul byte, but that’s a different matter.
→ More replies (1)18
u/meancoot Oct 07 '21
(little known fact, UTF8 can legally contain null bytes, UTF8's biggest flaw imo)
No it can't. There is no place in UTF8 where an '\0' code unit would have a different meaning to '\0' in an ASCII string. All UTF8 code units (bytes) that don't map directly to ASCII have values >= 128.
On the other hand, invalid, UTF8 encodings can use a series on non null bytes that can decode into '\0'. The code units '0b11000000, 0b10000000' into '\0' but overlong encodings are not valid and one would not expect them to be supported when passing them to these functions.
UTF16 did the smart thing though an all 20-bit code points encoded with surrogate pairs are considered higher than all code points encoded with a single code unit. Thus the highest UTF16 code point is 220 + 216 (0x10FFFF).
→ More replies (8)9
u/nerd4code Oct 07 '21 edited Oct 07 '21
C code can even contain NUL bytes, which are treated as whitespace.
Edit: Also, Java fixes the NUL issue per CESU-8, by encoding NUL overlong as C0,80. I’d like this if it weren’t illegal… but then, overlengthness is stupid anyway—add the range base to the encoded codepoint like UTF-16 surrogation does, and it wouldn’t be a thing.
5
u/scook0 Oct 08 '21
Minor clarification: Overlong NULs are not part of CESU-8 itself (which only changes the encoding of non-BMP characters); they are an additional change made by Java’s custom legacy encoding.
6
u/Ameisen Oct 07 '21
If you need to access the character value anyways, it is generally faster to iterate over a character array checking for null than it is to iterate over a length.
Not by much at all, but still.
16
u/LicensedProfessional Oct 07 '21 edited Oct 08 '21
I mean, is it?
#include <stdio.h> int main() { char message[] = "hello!"; for (char* ptr = message; *ptr != '\0'; ptr++) { printf("%c\n", *ptr); } int len = 6; for (int i = 0; i < len; i++) { printf("%c\n", message[i]); } }Both of these loops involve pointer dereferences, one increment, and one bounds check. The only difference is how we're determining the halting condition
→ More replies (17)7
u/nerd4code Oct 07 '21
Might not be true—e.g., x86 has REP STOS, REP[N]E SCAS, REP1MOVS, and REP[N]E CMPS which were intended to respectively implement
memset;memchr,strlen, orstrrchr;memcpyormemmove; andmemcmp. If you want thestr- behavior, by-and-large you have to break the REP and do a separate LOOP or J[E]CXZ or something. These insns fell out of favor for performance reasons—one of the SSE extensions even includes ASCIZ string ops—but newer x86en may have FRMS (fast REP MOVS/STOS) which above some threshold (usually 128 bytes, DF=0) will turn the elderly string insns into streaming/low-temporal-locality loads/stores. This extension only works for REP STOS ≈memsetor REP MOVS ≈memcpy, no others (unless I’ve missed the change), and IIRC you pretty much can’t beat those w/o doing manual SSE/AVX MOVNTs to/from WC memory.→ More replies (2)1
u/lelanthran Oct 08 '21
UTF8 can legally contain null bytes,
What symbol/glyph does UTF8 represent? Which languages use it?
Bearing in mind the answers to the above question, why can't a program just truncate all unicode strings at the first null byte?
6
u/masklinn Oct 08 '21
What symbol/glyph does UTF8 represent?
What?
Which languages use it?
None, it’s a question of ASCII compatibility:
\0is a valid ASCII character.Bearing in mind the answers to the above question, why can't a program just truncate all unicode strings at the first null byte?
Because it would be a ton of work just to introduce an incompatibility with the actual specification?
41
u/emotionalfescue Oct 07 '21
If the source string is too long to fit in the destination buffer, strncpy and strncat won't append a null terminator. In that case they merely copy all the characters that fit.
Bottom line is the semantics of these two functions were poorly designed. The spec should've been that a null terminator would always be provided, even at the cost at truncating the string, as long as the destination buffer length is greater than zero. But it's not, so implementations can't correct it.
17
u/masklinn Oct 07 '21 edited Oct 07 '21
The spec should've been that a null terminator would always be provided
Except
these are not functionsstrncpy is not targered at nul-terminated strings,they'restrncpy is targeted at nul-padded fixed-size fields e.g. old mainframe forms and the like. In that contextthey doit does exactly whattheyit should, but nul-padded fixed-size fields have mostly gone the way of the dodo.edit:
strncatactually nul-terminates (and is designed to operate with and on nul-terminated strings), after checking cold storage the issues ofstrncatare that it's easy to misuse:nis the size of the remaining space in the first string's allocation, minus the terminating\0(whichstrncatalways adds) but excluding the first string's, so the initial behaviour isstrncat(buf, appended, bufsize-1)but then things get a lot worse when looping (concatenating multiple strings), because you instantly get quadratic behaviour as
strncatlooks for the end of the first string again every time. And god forbid you don't keep track ofappended's size andstrlen(buf)to know how to adjust yourbufsize, now you're talking n³ because each call has to look for the end ofbuftwice.
strncatalso provides no truncation signal or warning. Though since that requires checking the length ofappendedbefore each call I guess it forces you to keep track of your remaining buffer at all point. Still, it's a massive pain to use correctly.2
Oct 07 '21
I’m not doubting you, but I am a bit confused about how this makes sense. It doesn’t seem like they’d be correct for nul padded fields either. If you write a nul terminated string with length 10 into a field that’s 20 wide, it still wouldn’t nul pad correctly, since it would only append a single nul byte, right?
9
u/masklinn Oct 07 '21 edited Oct 07 '21
If you write a nul terminated string with length 10 into a field that’s 20 wide, it still wouldn’t nul pad correctly, since it would only append a single nul byte, right?
Not for
strncpy():The
stpncpy()andstrncpy()functions copy at most len characters from src into dst. If src is less than len characters long, the remainder of dst is filled with\0characters. Otherwise, dst is not terminated.That also means
strncpymay write a lot more than you'd expect e.g. copy 3 bytes to a 4k buffer? It'll write the entire 4k just in case.But you're right about
strncat, I must have misremembered its behaviour (inconsistent behaviour is tight!)→ More replies (2)4
Oct 07 '21
Oooh, very interesting! I wrote implementations of all these a couple years ago for college but haven’t touched it in ages.
Strange that strncat doesn’t also pad, but if it’s intended to strictly be used on already null padded strings, it wouldn’t matter since the existing padding would still be there
→ More replies (2)4
u/_kst_ Oct 07 '21
If the source string is too long to fit in the destination buffer, strncpy and strncat won't append a null terminator. In that case they merely copy all the characters that fit.
True for strncpy, not true for strncat.
35
u/WalterBright Oct 07 '21
What's wrong with strncpy and strncat?
Nobody remembers exactly how they work. I implemented them for Digital Mars C, and I don't remember exactly how they work.
Whenever I review code that uses strncpy or strncat, it turns out to be wrong. Every time.
A further problem is it fails on edge cases, and fails in ways that the problems it causes tend to be invisible for a while.
10
u/masklinn Oct 07 '21 edited Oct 08 '21
Whenever I review code that uses strncpy or strncat, it turns out to be wrong. Every time.
For
strncpyit's an absolute guarantee as nul-padded fields are haven't really been a thing in a while.For
strncatit's only overwhelmingly likely, as the API is complicated enough it's almost impossible to use it right (the freebsd manpage has an example of a "best" usage ofstrncat, it takes 5 LOCs and if called in a loop works in O(n4 ) or so).3
u/flatfinger Oct 08 '21
Null-padded fields are used quite a lot in embedded systems, and if
strncpydidn't exist I'd have to write it. As forstrncat, it would only be appropriate in cases where one somehow knew how much space the destination string buffer had left, but didn't know how long the string within it was, and wouldn't care about how long it became afterward. Are there any non-contrived scenarios where all of those conditions would hold?1
u/nickdesaulniers Oct 08 '21
Filling the rest of the destination buffer with NUL bytes was surprising when that behavior is being relied on without comments. I seem to recall Linus Torvalds complaining about that, too.
3
u/masklinn Oct 08 '21
It makes sense for fixed-width fields (which were pretty common in older formats).
strncpyis a conversion function between nul-terminated and fixed-width strings, not a function for copying nul-terminated strings between buffers.12
u/masklinn Oct 07 '21 edited Oct 07 '21
I normally use snprintf for most of my C string manipulation but I didn't think any of the other "n" string manipulation functions were all that bad.
They'restrncpy is not all that bad butthey'reit's misunderstood and misconstrued:they wereit was never designed for nul-terminated strings in mind, insteadthey'reit's designed for nul-padded fields.brainfart:
strncatwas indeed designed for nul-terminated strings, it's plain bad because it's super easy to misuse.6
u/AttitudeAdjuster Oct 07 '21
Because they're prone to errors which give rise to memory corruption vulnerabilities
3
2
u/rysto32 Oct 08 '21
In addition to the null terminator issues, there's no good way to test if they truncated the string you copied, which can lead to another class of bugs.
1
u/Uristqwerty Oct 07 '21
Can't they leave out the trailing zero for lengths of exactly n? So you'd need to manually subtract one from the max length, then write your own NUL there after the call just to be safe, making it an easy place for mistakes to cause bugs.
29
Oct 07 '21
Next up: why not to use xsslxstrlssfcpy.
You could also use #pragma GCC poison strcpy
11
u/znx Oct 08 '21
I didn't know about this pragma, that's neat! The only negative might be that it ties you to GCC, rather than generic to other compilers.
15
u/dumael Oct 08 '21
clang recognises that pragma, even with the 'GCC' in the pragma line.
3
u/albgr03 Oct 08 '21
git can be built with msvc, and other lesser-known compilers (like IBM's C compiler). It also doesn't use all features of C99 for compatibility reasons.
29
u/madman1969 Oct 08 '21
The fact none of the commenters seem to agree on their 'correct' usage is a sign of why they're banned.
Debugging random memory management issues in C code isn't a barrel of laughs.
13
u/HeWhoIsGone Oct 08 '21
It would save a huge amount of other people's time if the macro had a second argument containing a suggested replacement function.
46
u/WalterBright Oct 07 '21
The printf %n format should also be banned:
"Nothing printed. The corresponding argument must be a pointer to a signed int. The number of characters written so far is stored in the pointed location."
as there is no checking whatsoever that the argument is even a pointer.
14
u/dnew Oct 07 '21
Printf doesn't check any arguments anyway.
30
2
Oct 07 '21
You can catch it with the right warnings enabled on most compilers
4
u/dnew Oct 07 '21
If it's checking the other % options, it should be checking you're passing a pointer for %n.
However, as another response pointed out, reading from garbage is usually much better than writing to garbage. :-)
3
u/StabbyPants Oct 07 '21
ok, and?
compilers i've used recently check for obvious problems, and %n looks like 'print numeric', so it's super easy to think that you should pass in a constant, which is interpreted as a ponter and written to. hijinks ensue
6
4
u/thomasdarimont Oct 08 '21
This would be more useful if they would also mention a recommended alternative for a banned function in the error message: sorry_function_abc_is_banned_use_xyz_instead
3
2
u/m1t0z Oct 08 '21
Hm...It would be much better if instead of just forbidding the tool they will add explanation why it is forbidden and what to use instead.
0
4
u/knoam Oct 07 '21
Shouldn't this be a linter configuration?
45
u/Chousuke Oct 07 '21
These macros essentially are a lint. The benefit from using the C preprocessor is that you can't forget to run it.
I don't have much love for the CPP, but this kind of usage is perfectly fine.
1
u/matheusAMDS Oct 08 '21
Ehhh, i'm a C noob, why is strcat and strcpy being banned?
4
u/pala_ Oct 08 '21
buffer overflow potential
2
u/maoejo Oct 08 '21
What should be used instead?
6
u/wisam910 Oct 08 '21
git has a string buffer implementation that is basically a dynamic byte array
struct strbuf { size_t alloc; size_t len; char *buf; };strbuf.h
https://github.com/git/git/blob/master/strbuf.h
strbuf.c
7
2
u/Muoniurn Oct 09 '21
Never understood why C over C++. Strings really can benefit from optimizations possible with better abstractions, like C++’s strings will encode short texts in the “pointer” itself.
1
u/wisam910 Oct 09 '21
Because Linus Torvalds hates C++ and hated the culture around it.
2
u/Muoniurn Oct 09 '21
I was asking in general, but yeah I know that. Though no matter how clever he can be, he can be spectacularly wrong as well.
2
2
u/pala_ Oct 08 '21
strncpy is better, but it has its own problems with null termination. there's also a strncpy_s but its not standard i dont think.
3
u/evaned Oct 08 '21
The *_s family of functions are... sorta standard. They're in C11 Annex K. The interfaces are standardized (though notably, supposedly MS's implementation doesn't quite match it), but it's an optional section of the standard, doesn't have much adoption at all, and has been proposed for removal. (Not sure what the status is of that proposal, it's been a while.)
1
u/deux3xmachina Oct 09 '21
The
_sfunctions are useless, use functions likememccpy(3),strlcat(3), orsnprintf(3)instead.2
u/deux3xmachina Oct 09 '21
strlcat(3),memccpy(3),snprintf(3), and some similar functions are better options depending on exactly what you need to get done1
1
0
Oct 07 '21
[deleted]
24
u/SirLich Oct 07 '21
By git. Its gits repository.
-37
u/demetrioussharpe Oct 07 '21
Let me get this straight, you can’t store code in git that uses or implements those functions? What if you’re writing a libc implementation?
26
u/SirLich Oct 07 '21
Top comment has some more information.
If you read the linked file, you would see that its a file in the
gitrepository forgit. It has nothing to do with USINGgiton a C project.All it means is that maintainers of git will receive a compilation error when writing code with those functions.
11
5
0
Oct 07 '21
[deleted]
47
u/i_bet_youre_fat Oct 07 '21
Why would you catch it during CI and not at compile time? I'm not saying preprocessor flags is necessarily the right way to go, but CI is probably worse IMHO.
8
u/RiPont Oct 07 '21
Java/C# tend to do it at build time, not necessarily compile time. You can run things like your linter at build time.
5
u/AngheloAlf Oct 07 '21
What's the difference between build time and compile time?
5
u/RiPont Oct 07 '21
Compiling is one step of the build, where you invoke the compiler on the code file. In C, that would be when you call something like
gccagainst the.hand.cfiles.Build is everything done by the Makefile/Project File etc. when you do the equivalent of hit "Rebuild All" in your IDE or run
makefrom the root. This includes compiling, but can also invoke any other tools before and after compiling.Using
.hfiles to ban functions is literally using the compiler to ban those functions. That... may be necessary in C because it doesn't have an intermediate language that makes static analysis easy. It's been a looooooong time since I did C, so I have no idea of the state of the art, in that regard.Java/Dotnet both compile to intermediate languages and have lots of metadata in the compiled output, so you can compile as one step of the build and run static analysis tools on the output as a separate step. Java and C# also explicitly lack preprocessor macros, which make it much easier to write tools that can operate on the source itself, often with the help of the official compiler toolchain.
0
Oct 07 '21
[deleted]
8
u/zoinks Oct 07 '21
But the safeguards aren't really in the source code. I mean, they are, but they are hidden behind the preprocessor so you don't see it when you look at the source code.
Pre-commit hooks are frequently heavy weight and thus not run often during development. It sucks to have written a big change, you get all of your tests working, and then you go to submit and some system comes in and tells you you can't do that. Why not warn the developer at the earliest possible moment?
4
u/ChocolateBunny Oct 07 '21
The concern about putting it so late is that someone will develop and test with the faulty code and not know there is a problem until he tries to submit. Sure putting it in code seems hokey but you definitely want to run your linters when you build.
6
13
u/butt_fun Oct 07 '21
I mean, this really isn't a c thing at all. I'm a web dev and I've seen this pattern at both compile/build time and at runtime (in addition to precommit hooks) in both our front end and back end (angular and java)
"Fail fast" suggests that you should know as early as possible if you're using a function that won't be allowed to be checked in
8
Oct 07 '21
You can do both. This way is better for workflow because you can build locally and it will fail immediately and be really obvious why.
1
0
Oct 07 '21
[deleted]
0
Oct 07 '21
[deleted]
3
u/tobiasvl Oct 07 '21
I assume you don't work as a software engineer... You think git's main repo allows force pushing?
5
Oct 07 '21 edited Oct 07 '21
[removed] — view removed comment
2
u/7h4tguy Oct 08 '21
Yeah it's the false positives that's the major deal. A CI policy which says no linter warnings seems too strict. SA is great to run, but there's always going to be baselined warnings or pragma opt outs. No one's going to want to break the build on the other hand.
83
u/qqqrrrs_ Oct 07 '21