WASHINGTON -- The House voted down a measure Thursday that would have ended the military's ability to indefinitely jail anyone without charge or trial, including U.S. citizens.

That ability was enshrined in law in a previous version of the National Defense Authorization Act. Some lawmakers tried to take it out of the NDAA for 2015, which was up for consideration on the House floor Thursday.

Under the law, signed by President Barack Obama on New Year's Eve in 2011, the military can detain and hold anyone if they are suspected of links to Al Qaeda or any of its affiliates and supporters. Obama pledged to never exercise the power, which stems from the Authorization to Use Military Force passed by Congress after the 9/11, even as he signed the law. He has not used it, and former President George W. Bush stopped using it in 2006.

But the option will remain on the books, after the amendment sponsored by Reps. Adam Smith (D-Wash.) and Paul Broun (R-Ga.) failed on a vote of 191 to 230.

"That is an enormous amount of power to give the executive, to take someone and lock them up without due process," Smith said during floor debate. "It is an enormous amount of power to grant the executive, and I believe places liberty and freedom at risk in this country."

"Our Constitution works, and we ought to value it," Smith added, noting that hundreds of terrorists have been tried, convicted and jailed in regular civilian courts.

Civil liberties groups were not surprised the measure failed. Nevertheless, they were disappointed.

"Indefinite detention is unlawful and unnecessary, and there's no basis to hold people picked up in the United States without charge or trial," said Raha Wala, a lawyer with Human Rights First. "Today's vote in the House was a disappointing failure to recognize that fact."