Yes &&
is short circuited and you are using it correctly.
If next
is NULL
string compare will never happen.
More Related Contents:
- Using boolean values in C
- Is bool a native C type?
- Objective-C : BOOL vs bool
- Parameter evaluation order before a function calling in C [duplicate]
- C99 boolean data type?
- What is “!!” in C? [duplicate]
- What is the purpose of the unary plus (+) operator in C?
- Why is a condition like (0 < a < 5) always true?
- Difference between _Bool and bool types in C?
- Setting extra bits in a bool makes it true and false at the same time
- Should C compilers immediately free "further unused" memories? [closed]
- how many bytes is this struct? – how many bytes is pointer to a struct? [closed]
- Why does printf not flush after the call unless a newline is in the format string?
- Why is the use of alloca() not considered good practice?
- Using LEA on values that aren’t addresses / pointers?
- Display an array of color in C [closed]
- How to test a static function
- Atomicity of `write(2)` to a local filesystem
- Rand Implementation
- C++ : why bool is 8 bits long?
- Can I get Unix’s pthread.h to compile in Windows?
- Why does open() create my file with the wrong permissions?
- Optimized matrix multiplication in C
- C – initialization of pointers, asterisk position [duplicate]
- multiple word string input through scanf( )
- segmentation fault using scanf with integer
- Reductions in parallel in logarithmic time
- Dynamic method dispatching in C
- how do compilers assign memory addresses to variables?
- Swift: How to call a C function loaded from a dylib