In D&D 3.5 or Pathfinder, is there a non-epic feat that allows you to make a ranged attack at an adjacent opponent without provoking an attack of opportunity?
Pathfinder has Point Blank Master:
Point Blank Master (Combat)
You are adept at firing ranged weapons in close quarters.
Prerequisite: Weapon Specialization with selected ranged weapon.
Benefit: Choose one type of ranged weapon. You do not provoke attacks of opportunity when firing the selected weapon while threatened.
Normal: Using a ranged weapon while you are threatened provokes attacks of opportunity.
Special: Starting at 6th level, a ranger with the archery combat style may select Point Blank Master as a combat style feat, but he must have Weapon Focus instead of Weapon Specialization in the selected weapon.
These more specific feats are also available for characters who can't meet its requirements:
For 3.5e, I can't find a feat. There is another way, however:
The Master Thrower prestige class (Complete Warrior) has the Defensive Throw ability, which lets you make a concentration check to use thrown weapons without provoking an op.
The Order of the Bow Initiate prestige class (Complete Warrior) has Close Combat Shot, which lets you use ranged weapons without provoking an op.
The spell Arrow Mind (Complete Adventurer/Spell Compendium) lets you avoid provoking an op with the listed types of bows
There's Point Blank Master in Pathfinder. It requires Weapon Specialization (which requires Fighter level 4), unless you're a level 6+ Ranger and taking it as a bonus feat at which point you only need Weapon Focus.
I don't see a similar feat in 3.5.
While not a feat, and quite specific, Pathfinder's Skirmisher archetype for Rangers has the following trick:
Defensive Bow Stance (Ex): The Ranger can use this trick as a swift action. Until the start of his next turn, his ranged attacks do not provoke attacks of opportunity.
If you don't find it necessary to spend a feat, and don't mind the loss of your few Ranger spells, the trick is a good alternative usable on a times per day basis.
In the Dragon Magazine #335 (Sept. 2005) Class Acts column "Favored Enemy Feats," John E. Ling presents the general feat No Threat to Me (91) that has the hefty prerequisites of base attack bonus +7, the feat Point Blank Shot (Player's Handbook 98), and the special ability favored enemy like that of a ranger. A creature that possesses the feat when the creature makes a ranged attack doesn't provoke attacks of opportunity from one the creature's favored enemy types that's picked when the feat's gained.
In other words, an archer that possesses the feat No Threat to Me (giants) wouldn't provoke attacks of opportunity for any ranged attacks she made while in any giant's threatened area.
If willing to go farther afield, the third-party but Wizards of the Coast-licensed Warcraft: The Role-playing Game (July 2003) presents the feat Close Shot (108) that is available as a fighter bonus feat and that has as its prerequisites a Dexterity score of 13, a base attack bonus of +4, and the feats Point Blank Shot and Precise Shot (PH 98). It simply completely eliminates provoking attacks of opportunity for making ranged attacks. However, it should be noted that this feat predates the epic feat Combat Archery (Complete Warrior (Dec. 2003) 151). Because of both the feat's status as an outlier and the far higher prerequisites of the feat Combat Archery, a DM may decline to allow the feat Close Shot into his campaign.
My answer(s) is specific to Pathfinder.
I see that people have answered with several viable options, but often require taking class levels in something. In the case of Point Blank Master you pretty much have to be a fighter due to one of the required pre-req feats.
There is the snapshot feat which came out in Ultimate Combat. While it does require many feats to get they are likely feats you would already take for a ranged weapon.
Snap Shot (Combat)
With a ranged weapon, you can take advantage of any opening in your opponent’s defenses.
Prerequisite: Dex 13, Point-Blank Shot, Rapid Shot, Weapon Focus, base attack bonus +6.
Benefit: While wielding a ranged weapon with which you have Weapon Focus, you threaten squares within 5 feet of you. You can make attacks of opportunity with that ranged weapon. You do not provoke attacks of opportunity when making a ranged attack as an attack of opportunity.
Normal: While wielding a ranged weapon, you threaten no squares and can make no attacks of opportunity with that weapon.
The only way I know is through the soulbow (complete psionics)prestige class.
close combat shot: At 4th level, you can attack with your mind arrow while in a threatened square and not provoke attacks of opportunity.