Based on the C++ spec, it will always throw std::bad_alloc when you use just plain new with no params, but of course there can be some non compliant compilers.
I would not code to be compliant with non c++ compliant compilers though. VC6 being one of them in this respect.
It is good practice though to always set your pointer to NULL after you delete them. So because of that, checking for NULL is still needed.
That being said, here are a couple options to cleaning up your code:
Option 1: Setting your own new handler
A safe way to clean up your code would be to call: set_new_handler first.
Then you could check for NULL in your handler and throw std::bad_alloc there if NULL is returned.
If you like exceptions better, then this is your best bet. If you like to return NULL better then you can also do that by doing a catch inside your new handler.
Option 2: Using overloaded new
The c++ standard header file defines a struct nothrow which is empty. You can use an object of this struct inside new to get its overloaded version that always returns NULL.
void* operator new (size_t size, const std::nothrow_t &);
void* operator new[] (void *v, const std::nothrow_t &nt);
So in your code:
char *p = new(std::nothrow) char[1024];
Here is a good refrence for further reading