Nos. 495, 562, Dockets 79-2093, 79-2098.United States Court of Appeals, Second Circuit.Argued November 27, 1979.
Decided May 8, 1980.
Richard R. Rowley, Albany, N.Y. (Rowley Forrest, P. C., Albany, N.Y., on the brief), for the union appellants-cross-appellees.
Stephen M. Latimer, Burlington, N. J. (Camden Regional Legal Services, Inc., Burlington, N. J., on the brief), for the inmate appellees-cross-appellants.
Barry R. Fertel, Deputy Asst. Atty. Gen., New York City (Robert Abrams, Atty. Gen. of the State of New York, George D. Zuckerman, Asst. Sol. Gen., New York City, on the brief), for the State officer cross-appellees.
Appeal from the United States District Court for the Southern District of New York.
Before TIMBERS, VAN GRAAFEILAND and NEWMAN, Circuit Judges.
NEWMAN, Circuit Judge:
 The modern sensitivity to the significance of gender in American life and law has made it inevitable that cases will arise where gender-based legal contentions conflict. This case arises in a context where that conflict can be expected to recur with some frequency: privacy rights versus employment
rights. Members of one sex assert a privacy right not to have their unclothed bodies viewed by members of the opposite sex. At the same time, members of one sex assert an employment right not to be discriminated against in job opportunities because of their gender. In this case, the privacy right is asserted by female prisoners, and the employment right is asserted by male prison guards, but the potential conflict of rights transcends the particular alignment of genders. Indeed, in this very case the challenged discrimination against the male guards is alleged to result in the impairment of employment rights of female guards. Resolution of such cases requires a careful inquiry as to whether the competing interests can be satisfactorily accommodated before deciding whether one interest must be vindicated to the detriment of the other. Fortunately this case is one where that inquiry yields a result that respects both privacy and employment rights.
 The case is here on appeal and cross-appeal from an order of the United States District Court for the Southern District of New York (Richard Owen, Judge), which seeks to protect the privacy interests of women inmates at the Bedford Hills Correctional Facility (“Bedford Hills”), a women’s prison operated by the State of New York. Forts v. Ward, 471 F.Supp. 1095 (S.D.N.Y. 1978). The order, id. at 1102-03, imposed various requirements, including a prohibition on the assignment of male guards to certain duties in the infirmary and housing units of the prison. The suit was brought by ten women inmates against State correction and personnel officials (“State defendants”) and the statewide union representing correction officers and two union officials (“union defendants”). The State defendants have not appealed. The union defendants have appealed only to challenge the portion of Judge Owen’s order that enjoins male guards from assignment to duties requiring observation of female inmates through the windows of their cell doors during nighttime hours. The plaintiffs have cross-appealed to challenge the denial of their motion for class certification.
 The background and procedural history of this litigation require some explanation. In February, 1977, pursuant to a change in state policy, male correction officers were assigned for the first time to duties within the living and sleeping corridors of Bedford Hills. Several months later, the inmate plaintiffs commenced this action, pursuant to 42 U.S.C. § 1983, on behalf of themselves and an alleged class of approximately 400 other women inmates at Bedford Hills.
Their complaint alleged that the assignment of male guards to areas of the prison where inmates were involuntarily exposed to view while partially or completely unclothed denied the inmates their constitutional right to privacy. In June, 1977, the District Court granted the plaintiffs’ motion for a preliminary injunction against assignment of male correction officers to parts of the housing and hospital units of Bedford Hills. Forts v. Ward, 434 F.Supp. 946 (S.D.N.Y. 1977). Upon appeal by all defendants, this Court reversed and remanded for an evidentiary hearing on the injunction motion, having concluded that disputed issues of fact existed. Forts v. Ward, 566 F.2d 849 (2d Cir. 1977).
 Upon remand, Judge Owen combined the hearing on the preliminary injunction with the trial on the merits and held a twelve-day non-jury trial in December, 1977 and January, 1978. Forty-three witnesses testified, and Judge Owen, accompanied by counsel, made a personal inspection of Bedford Hills. At Bedford Hills each inmate occupies an individual solid-walled cell measuring seven feet by ten feet and containing a bed and a toilet. Each cell has a solid door, controlled by guards at the end of each corridor. Each cell door has a clear glass window measuring six inches by nine inches. The interior of the cell, including the bed and the toilet, is visible to anyone in the corridor looking through the cell door window. Prison rules permit an inmate during the day to request that her cell door be closed and allow her to cover the cell door window for fifteen-minute intervals. At night the door is kept closed, but the window may not be covered.
 On November 20, 1978, Judge Owen issued his decision, Forts v. Ward, supra, 471 F.Supp. 1095. He found that female inmates, while completely or partially unclothed, had been subjected to “a certain amount of viewing” by male correction officers and that such incidents were “certain to occur again with some frequency” given the physical setup and rules of Bedford Hills, id. at 1097-98. The Court noted that though an “individual’s normal right of privacy must necessarily be abridged upon incarceration” in the interest of prison security, id. at 1098, inmates do retain some residual privacy rights, id. at 1099. With respect to the guards’ interest in equal job opportunity, the Court found “no dispute that the job of a correction officer at Bedford Hills can be equally well performed by any qualified and trained man or woman” but concluded that “equal job opportunity must in some measure give way to the right of privacy.” Ibid. Specifically, the Court ruled that the women inmates were entitled to be protected from being viewed by male guards when they were partially or completely unclothed — while receiving medical treatment at the prison hospital or while showering, using toilet facilities, or sleeping in the housing units. The opinion contemplated protecting the inmates’ privacy by a combination of changes in guards’ work assignments and minor structural alterations.
 Judge Owen found no reason to bar male guards from assignment to the housing corridors during the daytime hours since prison rules permitted an inmate to protect her privacy during those hours by covering the cell door window for up to fifteen-minute intervals while dressing or attending to personal needs. However, he found that because prison rules prohibited covering the door windows during nighttime hours, the assignment of male guards to the corridors during those time periods violated the inmates’ right of privacy. Id. at 1100-1101.
Judge Owen also found that the invasions of privacy occurring while inmates were showering or changing into and out of their clothes could be easily corrected by installation in the shower facilities of appropriate screens. Id. at 1101.
 Rather than immediately issuing an order implementing his opinion, Judge Owen directed the State defendants to submit a proposed order that, “while maximizing equal job opportunity, will afford each inmate the minimal privacy to which the court concludes she is entitled.” Id. at 1102. The proposed order submitted by the State defendants suggested two solutions to prevent viewing through the cell door window during nighttime hours: issuing to each inmate, upon request, a set of one-piece pajamas, commonly known as “Dr. Denton’s,” and changing the prison rules to permit inmates to cover their cell door windows at night for the same fifteen-minute intervals permitted during the daytime. The order entered by Judge Owen on April 12, 1979 rejected both of these suggestions in favor of an absolute prohibition against the assignment of male correction officers to duties during the nighttime “which require them under normal circumstances to observe female inmates through the windows of each inmate’s cell.” Forts v. Ward, supra, 471 F.Supp. at 1102. The rationale for this change was explained to the parties by Judge Owen at a conference held in late February, 1979:
. . . I do not think it appropriate to say to a woman, “In order to protect your privacy, you have got to be ensconced in a two-legged bag over the night or give up the right to privacy. It seems to me that she has the right to select appropriate sleep wear . . . because I don’t see any prison necessity for a particular designation of sleep wear and I don’t see that a person has to sleep in a Dr. Denton, if the temperature hits 90 or 95 . . in order that a man may have the privilege of walking up and down the corridor and looking in upon her. . . .
 Having decided to prohibit guards from nighttime corridor assignments primarily because he found the State’s sleepwear proposal unacceptable, Judge Owen found it unnecessary to accept the State’s additional suggestion that cell door windows could be covered for intervals during the night.
 The nature of the issues presented on appeal has been significantly shaped by the fact that the State defendants have elected not to challenge Judge Owen’s order. The acquiescence of the State defendants means that there is no longer any dispute between the inmate plaintiffs and New York as to whether the nighttime viewing of completely or partially unclothed women inmates by male prison guards violates the constitutional privacy rights of the inmates. We may assume for purposes of this appeal that such viewing is a denial of constitutional rights. But that issue remains whether the District Court’s remedy impairs protected rights of the prison guards. On their behalf the union defendants contend that
the portion of the remedy removing them from nighttime shifts in the housing units is unjustifiable gender-based employment discrimination in violation of Title VII of the Civil Rights Act of 1964, 42 U.S.C. § 2000e et seq. (1970 ed. and Supp. V).
 Before proceeding to the merits, we must first ascertain whether the District Court had jurisdiction to consider the guards’ Title VII defense. As a general rule, the filing of a timely charge with the Equal Employment Opportunity Commission (EEOC) is a prerequisite to the maintenance of a Title VII action in the District Court. United Air Lines, Inc. v. Evans, 431 U.S. 553, 555 n.4, 97 S.Ct. 1885, 1887, 52 L.Ed.2d 571 (1977) Smith v. American President Lines, Ltd., 571 F.2d 102, 105 (2d Cir. 1978). In this case, the union defendants have filed no charge, timely or otherwise, with the EEOC. Nevertheless, in the procedural posture of this case, exhaustion of administrative remedies is not required.
 When Title VII rights are asserted defensively, the failure of a court to consider these rights for lack of administrative exhaustion risks not only the entry of an overly broad order, but also protracted litigation. The union defendants had no Title VII grievance until after the entry of Judge Owen’s order. At that point EEOC consideration would have delayed the ultimate resolution of the litigation and been, at most, of only advisory value since the agency would have been without power to disturb an order of a federal district court.
 The merits of the guards’ Title VII defense appears to place their equal employment rights in opposition to the inmates’ privacy rights. While this Title VII grievance is asserted on behalf of men, we note that gender-based discrimination in prison employment opportunities generally disadvantages women. See, e. g., Dothard v. Rawlinson, 433 U.S. 321, 97 S.Ct. 2720, 53 L.Ed.2d 786 (1977); Gunther v. Iowa State Men’s Reformatory,
462 F.Supp. 952 (N.D. Iowa 1979); see “Balancing Inmates’ Right to Privacy with Equal Employment for Prison Guards,” 4 Women’s Rights Law Reporter 243 (1978). Moreover, even in this case, we are informed that removal of men from night shift duties would impair the employment opportunities of female employees at Bedford Hills by bumping them
from preferred daytime shifts to which they would normally be entitled by virtue of seniority.
 In most respects Judge Owen skillfully avoided an ultimate conflict between employment and privacy rights by carefully tailored adjustments to either facilities or work assignments. In protecting the inmates’ privacy at the prison hospital, the judge prohibited the stationing of male guards at locations where inmates could be viewed completely or partially unclothed. That precise limitation on job assignments has apparently caused no removal of male guards from normally assigned shifts. However, the remedy adopted to protect the privacy of the inmates in their cells during nighttime hours has placed privacy and employment rights in direct conflict and resulted in a denial of equal employment opportunities for the male guards and, as a consequence of their reassignment, for the female guards as well. We believe the process of making careful adjustments, which Judge Owen pursued for most of the disputes before him, can be continued to resolve the contested matter of nighttime observations.
 The male guards have been prohibited from the nighttime shifts to avoid the opportunity for them to view women inmates on those infrequent occasions when the inmates are completely or partially unclothed. There are obviously two ways to avoid that opportunity in every circumstance in which it exists: remove the men or obstruct their view. The availability of this choice of remedies to protect the privacy of the inmates was fully recognized by the District Court with respect to a portion of this case. For example, the inmates complained that their privacy was impaired when male guards had the opportunity to view them taking showers during daytime hours. Instead of removing male guards from day-time shifts, Judge Owen ordered installation of a translucent screen, which permitted only enough visibility to ascertain that the shower area was occupied. See Forts v. Ward, supra, 471 F.Supp. at 1101.
 We need not decide in this case to what extent an employer may be required to expend money or alter procedures to avoid a situation that, if uncorrected, would justify gender-based discrimination. In this case, the employer has already acknowledged its willingness to make necessary changes to eliminate the opportunity for viewing in the two circumstances that impair the privacy of the inmates during the nighttime hours.
 The first circumstance concerns the sporadic situations when the inmates are subject to viewing through the cell door window while they are changing clothes or using the toilet. The prison authorities offered to prevent these opportunities for viewing by amending the prison rules to permit the inmates to cover the window for fifteen-minute intervals during the nighttime hours, just as they are currently permitted to do during the daytime. There is nothing in the record to indicate why that proposed rule change would not protect privacy at nighttime as satisfactorily as it does during the daytime.
 The second circumstance concerns the opportunity for viewing the inmates while asleep, during which time their nighttime garments may fail to conceal private parts of their bodies. The prison authorities offered to solve this problem by issuing one-piece pajamas to any inmate who felt that her present sleepwear provided ineffective covering. Judge Owen found that proposal unsatisfactory, apparently because the item of clothing suggested by the prison authorities, a “Dr. Denton,” was unattractive (“a two-legged bag”) and uncomfortably warm on hot nights. We seriously doubt that the inmates’ interests in style or even in avoiding the occasional discomfort of warmth from a sleeping garment are of sufficient gravity to justify denial of equal employment opportunities. However, we need not resolve the appropriateness of any particular sleepwear, because we do not believe the District Court adequately explored with the State defendants the range of available clothing that might be obtained. The State defendants represented their willingness to provide a suitable nighttime garment, and we cannot believe that there do not exist on the market sufficient items from which a satisfactory choice can be made. Moreover, we do not think it is imposing on counsel to suggest that they can negotiate this aspect of the case without further litigation in a United States District Court. The privacy interest entitled to protection concerns the involuntary viewing of private parts of the body by members of the opposite sex. Since appropriate sleepwear can sufficiently protect that interest, its use should be preferred to any loss of employment opportunities. We do not agree with the inmates that their privacy interest extends to a protection against being viewed while sleeping by male guards so long as suitable sleepwear is provided. Nor do we agree that any legally enforceable rights of inmates sufficient to impair employment rights can arise from an inmate’s preference for sleepwear of her choice or for none at all.
 We therefore vacate so much of the order appealed from as prohibits the assignment of male guards to the nighttime shifts in dormitories of Bedford Hills and remand for further proceedings to revise the order with appropriate means to eliminate the opportunities for viewing that have been found to impair the privacy rights of the inmates. In doing so, we do not minimize in any way the significance of the privacy interests of the inmates that the District Court has sought to protect. We do not elevate the employment rights of the guards above any protectible privacy rights of the inmates. We simply conclude that in the circumstances of this case the remedy proposed by the State will accord adequate protection to the privacy interests of the inmates by means that will avoid any denial of the guards’ rights to equal employment opportunities. Since that is so, it is important for the employment opportunities of both sexes that the portion of the District Court’s remedy requiring unjustified gender-based discrimination be set aside.
 As to plaintiffs’ cross-appeal from the denial of class certification, we find no basis to disturb the District Court’s exercise of discretion. The order appealed from benefits all members of the alleged class, and the State defendants have not appealed and have explicitly indicated a willingness to comply. In these circumstances, class certification would be “largely a formality,” Galvan v. Levine, 490 F.2d 1255, 1261 (2d Cir. 1973), cert. denied, 417 U.S. 936, 94
S.Ct. 2652, 41 L.Ed.2d 240 (1974), and was properly denied, wholly apart from the issue of whether disputes within the class concerning the scope of relief impaired the capacity of the named plaintiffs adequately to represent the class.
 Vacated and remanded for further proceedings consistent with this opinion.
. . . somewhere between 6:30 and 6:45 in the morning, the inmates are awakened and all the cell doors are simultaneously rolled open by a master switch. . . . At that point, the inmates obviously do not have even the door to protect them from anything. Some inmates may wish to use the toilet upon arising; some, while waiting, may wish to change from night clothes into day clothes; one may find her night clothes and bedding visibly soiled from an unexpected menstrual flow and wish to clean up; yet the present rules for the security of the prison require that each inmate present herself to be counted at that hour regardless of the state of her clothing or the calls of nature.
471 F.Supp. at 1101 (footnote omitted). Prior to the entry of his final order, the prison procedures respecting the morning count were changed. Thus, Judge Owen’s order merely called for a continuation of the “present procedure . . . insofar as inmates are told five minutes before the count that the count will occur, and that under normal circumstances, during this five minute period no male officers shall enter the housing unit corridors.”Id. at 1102-03. On appeal, the union defendants have raised no objection to this portion of Judge Owen’s order.
The Employer and the Union agree that the provisions of this Agreement shall be applied equally to all employees in compliance with applicable law against discrimination as to age, race, creed, color, national origin, sex, disability, marital status and political affiliation. (emphasis added).
The agreement also provides that “job assignments and shift selection shall be made in accordance with seniority[,] provided the employee has the ability to properly perform the work involved.” An employee or his union representative is generally entitled to assert his contractual rights as a defense against an action that implicates those contractual rights. See Equal Employment Opportunity Commission v. American Telephone and Telegraph Co., 506 F.2d 735, 739, 741-42 (3d Cir. 1974) (union entitled to intervene to challenge consent decree for limited purpose of protecting its interests in its collective bargaining agreements); Stallworth v. Monsanto Co., 558 F.2d 257, 268-69 (5th Cir. 1977).
 VAN GRAAFEILAND, Circuit Judge, concurring:
 This case presages a problem that will occupy more and more time of the federal courts — the balancing of conflicting interests that have been elevated to the category of statutory or constitutional rights. In this case, the female guards at Bedford Hills assert the right to be treated as men, while the female inmates assert the right to be treated as women. Because Judge Newman has resolved their differences in Solomonic fashion, I concur. However, I think it would have been better if the problem had been left in the hands of the prison authorities. See Bell v. Wolfish, 441 U.S. 520, 547-48, 99 S.Ct. 1861, 1878, 60 L.Ed.2d 447 (1979).