In the second highly publicized police misconduct case to be tried in federal court here within two years, a judge again has granted probation to officers who had been fired for their part in the death of an unarmed prisoner.

A jury in federal court last month found former Houston policemen Danny Howard Mays, 28, guilty of participating in planting a gun make the shooting of a Louisiana teen-ager look like self-defensse and of then lying to a federal grand jury.

Mays was acquitted of intentionally depriving the youth of his civil rights with the result that he dieds, a charge that could have meant life in prison.

Witnesses testified that Mays shot Randy Webster, 17 after the youth alegedly stole a van Feb. 8, 1977, and led police on a high-speed chase. Mays told police, a state grand jury and a federal grand jury that he shot Webster after the youth lunged at him with a gun.

However, a cabdriver who was at the scene and a fellow policemen who testified under a grant of immunity said Mays grabbled Webster as he tried to come out of the van with his hands up, threw him to the ground and shot him in the head at close range.

he cover-up began to unravel after Assistant U.S. Attorney Lupe Salinas traced the weapon found at Webster 's side to the Houston police department's property room.

Defending the light sentences in a 17-page memorandum, Judge Finis E. Cowan suggested that the shooting was an accident and that the defendants were thrust into an emergency that they did not create. He said their persisting in the cover-up was motivated "at least in part because of loyalty to comrades," which he said could not be "totally condemned."

And he repeatedly noted that the testimony of the government's chief witness, former oficer John Thomas Olin, had been "purchased by grant of immunity."

Cowan said Olin's testimony and that of another former policeman with immunization, William Byrd, who said he supplied the throw-down gun, "must be viewed with great caution." He also said the testimony of the cabdriver "was to some degree suspect."

More than a year ago, federal Judge Ross Sterling granted probation to three former Houston policemen convicted of violating the rights of young Mexican-American Joe Campos Torres by beating him up and throwing him in a bayou where he drowned. They could have sentenced to life in prison.

Mary Sinderson, an assistant U.S. attorney who participated at both the Webster and Torres trials, said she felt that prison terms for Mays and Holloway would have deterred other officers from taking similar actions. "The police are already laughing at us about the Torres case," she said.

Meanwhile, a state judge ordered reinstatement with back pay for Paul Dillon, a fired police supervisor who had been the first man on the scene of the Webster shooting afrer Mays, Holloway and Olin. Dillon had been tried wirh Mays and Holloway and was acquitted of all charges.

The judge's ruling appeared based on the argument that the statute of limitations on Dillon's alleged violation of departmental rules had passed six months after the Webster shooting.

Police Chief Harry Caldwell, whose firing of Dillon was upheld by the city's civil service board, had maintained that the six-month period begins once a covered-up offense is discovered. He said the state judge's ruling seemed to be telling officers, "If you can caneal wrong-doing for six months, you're home free."