Look for dirt, first, especially under the pistol's ejector star. Clean the entire area with a toothbrush.
Next, check to see that the ejector rod isn't bent. Just a very slight kink in the rod will give you the effect you mention.
It's also an outside chance that the gun's ejector rod is starting to unscrew. Check for looseness by very carefully rotating the rod.