As the grep documentation states in its discussion of the -r option:
"If no folder name is given, grep command will search the string inside the current working directory."
therefore, your original command line (ignoring the -l flag):
grep -lr search-pattern *.c
is recursively searching, within the files in the current directory whose filenames end in .c, for "search-pattern". It will find nothing if there are no such files in the current directory.
Your second command line (again ignoring the -l flag):
> grep -lr search-pattern *
is recursively searching for "search-pattern" in all files in the current directory and all subdirectories (because * is being interpreted as a wild card for "folder name").
Your two command lines will both "recursively search a pattern in all the .c files", the first in the current directory, the second by recursive descent of the current directory and all subdirectories, if you eliminate the "-l" flag from both of them.
The discussion that follows presumes that your intent is simply recursing over the .c files in the current directory for your search (as implied by your first command line).
Discussion:
My preference would be to leave the task of finding and listing the files of interest to ls the utility that is built for that purpose, having it list them one filename per line. I would then construct the command line for grep with xargs (the utility built for that purpose) from the output of ls and the pattern that you want grep to look for (thus using grep in the most natural way). The resulting command looks like this:
ls -1 *.c | xargs grep "C.*t"
Test Case:
In a directory with the following contents:
Erlang hello.cs hello.exe somefile.c someotherfile.c
to follow your description of the intent, I will expect my command line to find the files somefile.c and someotherfile.c, and search within these for a pattern that starts with a capital C and ends with a lowercase t.
The file somefile.c consists of:
Ignore this!
Content
... this too ...
... and this.
The file someotherfile.c consists of
Content to find
Ingore this
and our command
ls -1 *.c | xargs grep "C.*t"
produces this result:
somefile.c:Content
someotherfile.c:Content to find
supplying the -v argument to grep gives us the inverse result, i.e.,
the command:
ls -1 *.c | xargs grep -v "C.*t"
gives the result:
somefile.c:Ignore this!
somefile.c:... this too ...
somefile.c:... and this.
someotherfile.c:Ingore this