The land in controversy is the northeast quarter of section 1, in township 95 north, of range 41 west, in O’Brien county. The plaintiff claims ownership thereof by virtue of the following statutes and conveyances, to-wit: An act of congress entitled “An act for a grant of land to the state of Iowa in alternate sections, to aid in the construction of a railroad in said state,” approved May 12, 1864 (13 St. at Large, 72); chapter 134, Acts Eleventh General' Assembly; chapters 16, 42, 58, Acts Twelfth General Assembly; chapter 96, Acts Sixteenth General Assembly; chapter 21, Acts Seventeenth General Assembly; patent from the United States to the state of Iowa; patent from the state of Iowa to the Chicago, Milwaukee and St. Paul Railway Company; deed from the said company to plaintiff; also by virtue of an alleged compliance with the act of congress. cited and certain of the acts of the general assembly. The defendant claims an interest in the land by virtue of an application made by him to enter it under the homestead laws of the United States, and by virtue of his occupation and improvement thereof. The district court found and adjudged that plaintiff was the unqualified owner of the premises, with the right of immediate possession.
I. The act of congress approved May 12, 1864, granted to the state of Iowa, “ for the purpose of aiding in the construction of a railroad from Sioux City, in said state, to the south line of the state of Minnesota, at such point as the state of Iowa may select;” also “for the use and benefit of the McGregor Western Railroad Company, for the purpose of aiding in the construction of a railroad from a point at or near the foot of Main street, South McGregor, in said state, in a westerly direction, by the most practicable route, on or near the forty-third parallel of north latitude, until it shall intersect the said road running from Sioux City to the Minnesota state line, in the county of O’Brien, in said state, — every alternate section of land designated by odd numbers, for ten sections in width on each side of said roads.” The act provided that the lands granted *541should be subject to the disposal of the legislature of this state for the purposes stated, and for no other. It further provided that, if the McGregor Western Railroad Company or assigns should fail to complete at least twenty miles of its road during each year from the date of its acceptance of the grant, the state might resume the grant, and so dispose of it as to secure the completion of a road on the line specified, upon such terms, and within such time, as the state might determine. Section 5 was as follows : “And be it further enacted that, as soon as the governor of said state of Iowa shall file, or cause to be filed, with the secretary of the interior, maps designating the routes of said roads, then it shall be the duty of the secretary of the interior to withdraw from market the lands embraced within the provisions of this act.” The grant was accepted by the state of Iowa, in trust for the purposes designated by the act. In the year 1868, the McGregor Western Railroad Company having failed to comply with the provisions of the granting act, the grant, so far as it was designed for the benefit of that company, was resumed by the state, and conferred upon the McGregor and Sioux City Railway Company, afterwards known as the McGregor and Missouri River Railway Company. In the year 1876, the terms of the grant to the last-mentioned company not having been complied with, the grant, excepting the land lying within twenty miles of the line of ,the. Sioux City and St. Paul Railroad Company, was resumed by the state, and regranted to the McGregor and Missouri River Railway Company. That company having failed to meet the requirements of the act of the general assembly of 1876, the grant to it was resumed by the state in the year 1878, and conferred upon the Chicago, Milwaukee and St. Paul Railway Company, by which a railway was built from Algona to Sheldon, where it intersected the Sioux City and St. Paul Railway in O’Brien county. A railway was thus completed on substantially the line contemplated by the act of congress, having been constructed, by the different beneficiaries of the grant named in the act of congress, and *542the several acts of the general assembly of the state of Iowa. The completion of the road was certified to the secretary of the interior by the governor of the state on the tenth day of November, 1878. Previous to that time, to-wit, in June, 1873, the general government had patented the land in controversy, with other lands, to the state of Iowa, for the use and benefit of the Sioux City' and St. Paul Railroad Company, under the act of congress of May 12, 1864.
In the year 1879 the Chicago, Milwaukee and St. Paul Railway Company instituted an action in the circuit court of the United States for the district of Iowa, to which the Sioux City and St. Paul Railroad Company, certain trustees, and the governor and register of the state land-office of the state of Iowa, were made parties defendant. The. purpose of the action was to recover certain lands to which the Milwaukee company claimed title, including that in controversy, by reason of having complied with the terms of the grant to it. The litigation extended through several years, and included an appeal to the supreme coiirt of the United-States. See 117 U. S. 406; 6 Sup. Ct. Rep. 790. It resulted in a final decree rendered on the twenty-first day of May, 1886, which determined, among other things, that the land in question belonged to the Milwaukee company, and required the Sioux City and St. Paul Railroad Company to convey it to that company.
Appellant took possession of the land in February, 1884, and during that month he made application to enter it under the homestead laws of the United States. He built a house upon the land, made other improvements, and has resided thereon since March, 1884. His first application to enter it seems to have been rejected or withdrawn, as he made a second one in September, 1885. The evidence as to that is meager, but, since he took an appeal from something not stated, we infer that it was rejected. Defendant claims some right to enter the land by virtue of a letter from the commissioner of *543the general land-office written in 1884, and a conversation had with him in 1885, but the record does not disclose what was contained in the former, or said in the latter.
II. On the thirtieth day of August, 1864, the McGregor and Western Railroad Company filed in the office of the commissioner of the general land-office a map showing the location of its road.- The western terminus of the road thus indicated was in section 19, township 95 north, of range 40 west, in O’ Brien county, at a proposed intersection with the Sioux City and St. Paul railroad. The proposed western terminus was south and east of thé land in controversy. On the twelfth day of September, 1864, all the odd-numbered sections of public land, within twenty miles of the line of road as shown by the map, was withdrawn from the market. After that time, the line of the Sioux City and St. Paul railroad was so changed that it passed through the northwest corner only of O’Brien county; thereby making it impossible for the McGregor road to intersect it at the point first proposed, and requiring the point of intersection to be at least nine miles further north, and ten miles further west. In May, 1868, the commissioner of the general land-office requested that the McGregor company file a map showing the true location of its line through Clay and O’Brien counties, to the point of its intersection with the Sioux City and St. Paul road in O’Brien county. In November of the same year, the commissioner insisted that the surveying to determine the final location be done without delay, in order that the land to be held at $2.50 per acre, within ten miles of the located line, might be determined in his office. In March, 1869, the McGregor company asked permission to withdraw its maps of definite location from the general land-office, and to relocate its road from the west line of range 27 to the intersection with the Sioux City and St. Paul railroad; stating that such relocation was made necessary by the change in the line of the last-named road. The permission asked *544was refused by the secretary of the interior in May. 1869, bn the ground that the road having been once located, and the lands of the grant having been withdrawn from market, there was no authority for accepting a new location. However, in January, 1869,' the McGregor company filed in the general land-office a map of the definite location of its road through Clay county, as amended; and in September of the same year filed a similar map, showing the definite location of its road in O’Brien county. Thereafter, the maps last filed were treated by the officers of the general land-office in instructions given to registers and receivers and otherwise, as showing the true line of the McGregor road through the counties named. The new line was north of the old "from a point in the latter on the east boundary line of Clay county to the point of intersection with the Sioux City and St. Paul road in O’Brien county, and contained several abrupt changes in direction. The line, as finally constructed, varied somewhat from the second line of location, as shown by the map, the variation in places amounting to several miles; but the constructed line was more direct than the second line of location, and avoided several of the changes in direction of the latter.
In December, 1879, the attention of the secretary of the interior was called to the fact that the road of the Milwaukee company, from Algona westward, was not constructed upon the line of definite location indicated by the maps of 1869. In April, 1880, the secretary determined that the variation between that line and the one upon which the road was built was not sufficient to destroy the identity of the road; that it was constructed on the most practicable location, and met the requirements of the grant; and that the state was entitled to patents for the granted lands. The location, as shown and made by the map of 1864, does not seem to have been considered by the secretary in rendering his decision; but, in' an official letter, written in 1870, by the commissioner of the general land-office, it was *545treated as a temporary location as to O’Brien county, not definitely fixing the line of the road.
III. The questions raised by the pleadings are numerous, but most of those raised by the answer have been waived in this court. The matter now in controversy is stated by counsel for appellant as follows: “The vital question is, having located the line of road in August, 1864, and filed the map of definite location in the office of the secretary of the interior, and had the lands inuring to the grant withdrawn, based upon such location, can the line of definite location be changed by the company without the consent of congress, and, if changed, does the change extend or change the land grant as fixed by the definite location of the line of road in 1864 ? ” The land in question was not within the limits of the grant, as indicated by the map of 1864, but is within the limits as shown by the maps of 1869, being less than ten miles therefrom, and is within eight miles of the road as finally constructed.
It is contended by appellant that all the requirements of the law in regard to the definite location of the road were fully complied with in 1864, and that the location then made was final, in the absence of consent by congress to a change; and that, as such.consent was not given, the relocation of the road did not have the effect of extending the grant to land not included by the first location. In 1864, the line of the road was surveyed, a map showing the location was filed in the general land-office, and apparently accepted, and the odd-numbered sections within twenty miles on each side of the line thus located were withdrawn from the market. In ordinary cases, that would have been sufficient to locate the road definitely, for the purposes of the grant. Van Wyck v. Knevals, 106 U. S. 360; 1 Sup. Ct. Rep. 336; Railway Co. v. Dunmeyer, 113 U, S. 629; 5 Sup. Ct. Rep. 566; Walden v. Knevals, 114 U. S. 373; 5 Sup. Ct. Rep. 898.
But the rule contended for has no application to a case where the attempted location was not authorized *546by the terms of the grant. In such a case, the filing and acceptance of the map could not have the effect of waiving the requirements of the granting act. In this case the act of congress required the McGregor company to build in a westerly direction until it should intersect the Sioux City and St. Paul road in O’Brien county. A road built on the line indicated by the map of 1864 would not have fulfilled that requirement; therefore, it was. not the line contemplated by the granting act. When that fact became apparent, it was proper for the railway company to make a new survey, and file a new map, which should meet the requirements of the grant; and, when that was done, and the location was approved, the new line became the one to fix the limits of the land grant. It was not a relocation, but an original location, within the meaning of the granting act.
IY. It is said that the right to make a second location was denied by the secretary of the interior. He denied permission to the McGregor company to relocate its line of road west of range 27, but it is shown that the relocation of the line from a point forty miles or more west of range 27, to-wit, the east line of Olay county to an intersection with the Sionx City and St. Paul road, in O’Brien county was permitted and approved. It is true the road as built was not altogether on the line adopted in 1869, but the variations were deemed_ proper by the secretary of the interior, who held that the line as built met the requirements of the law. There is nothing in the record to overcome, the presumiótions which necessarily exist in favor of the legality of the acts of the officers of the general land-office.
The question of the legality of the location of 1869 was fully presented by the answer of the principal defendants in the case of Chicago, M. & St. P. Ry. Co. v. Sioux City & St. P. Ry. Co., heretofore referred to, and appellee contends that its validity was necessarily affirmed in that case by the supreme court of the United *547States. The opinion of that court is found in 117 U. S. 406; 6 Sup. Ct. Rep. 790. It does not decide the question in terms, and for that reason is not. wholly satisfactory as an authority in point. We think it is true, however, that the opinion was based in part upon the conclusion of the court that the location of 1869 was valid under the granting act of 1864.
V. Having reached the conclusion that the location of 1869 was valid and effectual to include the land in controversy in the grant, it becomes unnecessary to decide other questions referred to by counsel. The judgment of the district court is Abbirmbd.