I was under the impression the C++ standard moves in lockstep with C so that all valid C programs should also be valid C++ programs.
They do try and stay reasonably consistent so for example Long Long moved from C to C++. And C99 has reduced some other incompatibilities by incorporating C++ features such as // comments and mixed declarations and code.
Many C++ compilers actually are C/C++ compilers that decide what language to compile depending on command line flags and/or file name extension.
int* foo = malloc(sizeof(int));
Is invalid C++. int* foo = (int*)malloc(sizeof(int));
in C++ or the compiler gives a type error.