The first time I got a press credential, in the mid-1970s, my boss made sure I knew having it was a privilege, not a right. “Don’t do anything that will make me ashamed of you,” he warned. I’ve kept those words in mind over the past 40 years, though I might not always have lived up to the standard he set. It’s something the current crop of young journalists might want to ponder.

Since then I have covered wars, riots, trials and crime scenes, always reminding myself that I was a spectator, not a participant. In Poland, I was chased down by riot police who didn’t care that I was a reporter. I was in the wrong place at the wrong time and paid for it.

In El Salvador, I came upon the bodies of six Jesuit priests, two of whom I knew well, who had been murdered hours before. I wrote the story, and kept my personal feelings out of it.

So when I read that as many as six journalists had been detained and charged with felonies during riots in Washington D.C., on the day Donald Trump became president, the first question I had was: were they taking pictures or taking part?

Two of those detained were described in news stories as “journalist and activist.” I don’t know if that is accurate, but I do know that it’s not possible to be both at the same time. A journalist who uses his or her credentials to gain access to an event -- whether it’s a speech, a battlefield or a protest march – gives up the right to be part of the action. You can’t riot while you’re working and expect your press pass to protect you.

Steven Nelson of U.S. News was covering the protests near 12th and L Street, where windows were being smashed and at least one vehicle set ablaze, when he realized the group he was in had been hemmed in by the DC police.

“I was not allowed to leave the group that had been detained,” Nelson told me. “After an hour, two local NBC reporters were allowed to leave after their boss called a lieutenant, and I was too. I think I just lucked out.” Nelson told me he was wearing his press credential and tried to identify himself as a reporter. Many of the rioters were dressed in black. Nelson was wearing a button down blue shirt and a pea-coat.

I wasn’t there, so I don’t know what happened. It sounds like Nelson was carrying out his job, not his right to protest. I do know you can’t do both at the same time. Nelson says he was hit with pepper spray fired into the crowd. Well, a reporter who puts himself in a dangerous situation may pay a price. A press badge won’t ward off pepper gas. That’s not a violation of the First Amendment. It’s bad luck, and maybe a lesson learned.

Carlos Lauría, the senior Americas program coordinator for the Committee to Protect Journalists, knows that reporters take risks. “When they cover this stuff, they accept the fact that some of these protests will turn ugly. But it’s a different thing for them to face these excessive charges.” The U.S. Attorney’s Office in D.C. says it’s looking over each charge individually, and will decide how to proceed on a case-by-case basis.

Journalists aren’t very popular these days. President Trump says he has a “running war” with the Fourth Estate. And news organizations have returned the favor, with almost unremittingly negative coverage and comments.

How’s that working out for everyone? A Gallup poll late last year showed fewer than a third of the country has a great deal or fair amount of trust in the news media.

Those who are fortunate enough to make their living in this profession cannot simultaneously exercise their First Amendment rights with abandon, and expect to be considered objective. Most pilots know better than to drink before they climb into the cockpit though liquor is legal. Journalists have the same right to free speech as the rest of the country. Just not while they're working.