What I mean by safe is that Will Smith and Denzel, etc. usually play black male heroes that don't have sex and don't provide much of a threat to the prevailing social order or white male Alpha status. Rarely are they rebels, they are usually cogs in the machine. The heroes/protagonists they play often are restricted in ways that heroes played by white males are not, particularly when it comes to sexual conquest. I think black sexuality is still something that is uncomfortable for a lot of non-black audiences to see.
About the comics, I made a distinction between headliners and those who are just in books. John Stewart, the black Green Lantern, currently is not a headliner, though he is featured in the Hal Jordan Green Lantern/GLC books. Though I'm a little disappointed that Geoff Johns' wonderful character work hasn't been used for Stewart. As mentioned by myself and others, blacks also feature prominently on some of the DC teams: Cyborg (formerly of the Titans) and Vixen on the Justice League, and Static on Teen Titans. Mr. Terrific in the JSA and Black Lightning in the Outsiders, Amanda Waller in Suicide Squad, etc. DC has also been doing miniseries for some of their black heroes, Vixen, Cyborg, and Black Lightning last year. There had been plans to bring back the Milestone characters but DC chose not to, except for Static, and a Milestone Forever event that's supposed to wrap up the Milestone storylines. So, for DC there are two black headliners, Azrael and Unknown Soldier. Unfortunately Firestorm and Blue Beetle (a Latino) solo series were cancelled within the last couple years.
For Marvel, there are two black headliners, Black Panther and Dr. Voodoo (whose book will be cancelled with issue #5). Similar to DC, there are some black characters who feature prominently on the Marvel teams like Luke Cage in the Avengers, or are valued sidekicks like Falcon in the Captain America books. Though overall I think Marvel has attempted to do more with its black characters and attempted to give them solo titles more. Off the top of my head, I can think of Blade, War Machine, New Warriors (leader Night Thrasher) were all recent cancelled series of the last two or three years with black male leads. There's also been a Storm miniseries, Luke Cage: Noir, and the Blue Marvel. Bishop might have had a mini too. And Marvel produced The Truth, one of the best Captain America stories, one of the best comic book superhero stories about race I've ever read. Though I'm disappointed in Marvel's lack of promotion of the crossover DoomWar event that's about to break out in the pages of Black Panther that would include Dr. Doom, FF, Wolverine, and Dead Pool. Even when they give BP an A-List event, Marvel shoots itself in the foot by not promoting it.
I don't think its a simple issue of the market determining if black comic heroes are successful without looking at that market and the overall disinterest that the largely white, male comic book reading audience has displayed for black headline characters. Part of it is probably the talent/lack of on the books, but that can't be the sole reason, not after decades. Also, you have to factor in longtime readership and loyalty. Some people only read what they grew up reading, and if they grew up in a time when almost all the comic characters were white, that's what they stick with. Many probably don't even fathom how lily white those books are, or remain. It's not an issue for them. Perhaps because their social interactions remain largely white and it might be a reflection of their reality. But ultimately, I think its a white/non-black inability to identify with blacks, for some whites or others to maybe feel that can't understand or don't want to understand, or can't empathize with a black character so they don't pick up the book. The power fantasy element might also come into play. Some people might live vicariously through comic book characters, they might aspire to be like those characters, and I don't think too many people, white or black for that matter, really want to be black. They might want to 'act' black or ape the 'black aesthetic', but to really be black, is another matter.