Relator Edward Fox, was arrested in Doylestown on February 14, 1948, and committed to Bucks County prison for a further hearing. On February 16, 1949, after hearing before Justice of the Peace Gulick of Doylestown, he was held for court and committed to the Bucks County prison pending trial on various charges of burglary, larceny, receiving stolen goods and violation of the- Uniform Firearms Act. On February 26, 1948, upon presentation of a warrant by two Philadelphia police officers to the warden of the Bucks County prison and with *776the consent of the district attorney of Bucks County, the relator was released to the Philadelphia County authorities. On a complaint sworn to on March 1, 1948, charging relator with robbery in Bucks County, a detainer was lodged on this charge with the Philadelphia authorities. Three transcripts were filed by Justice of the Peace Gulick on March 22, 1948, and one transcript by Justice of the Peace Horace Cooper on March 10, 1948, the latter being on the robbery charge. On April 14, 1948, while still in the custody of the Philadelphia County authorities, relator pleaded guilty to criminal offenses before the late Judge Harry S. McDevitt of Philadelphia County and was sentenced to imprisonment in the Eastern State Penitentiary for a term of not less than 10 years nor more than 30 years, such sentence to be computed from March 5, 1948, which was the date of commitment of relator in Philadelphia County.
On May 18, 1948, while relator was serving the above mentioned sentence imposed by the late Judge McDevitt, bills of indictment nos. 24, 25, 26 and 27, May term, 1948, charging relator with the offenses before mentioned, were submitted to a grand jury in Bucks County and true bills found.
On May 23, 1950, relator was returned to Bucks County for trial on bills of indictment, nos. 24, 25 and 26, May term, 1948, bill no. 24 charging him with violation of the Uniform Firearms Act, bill no. 25 charging him with larceny and receiving stolen goods, bill no. 26 charging him with burglary, larceny and receiving stolen goods. Although relator had indicated his desire to plead guilty to the charges at the hearings before Justice of the Peace Gulick,. he nevertheless pleaded not guilty to all three bills of indictment when arraigned before President Judge Hiram H. Keller of Bucks County and thereupon was put on trial for those offenses. After two days of trial, relator changed *777his plea from not guilty to guilty on bill no. 26 and on the second count of bill no. 24 in which he was charged with carrying a firearm without a license. Bill no. 25 and the first count of bill no. 24 were nolle prossed. Relator, at this time, also pleaded guilty to bill no. 27 for which he was not on trial.
Judge Keller sentenced the relator on bill no. 26 to pay the costs of prosecution, a fine of $5 and that he undergo imprisonment in the State Penitentiary for the Eastern District of Pennsylvania, for a period of not less than five years nor more than 10 years, to begin and be computed from the expiration of the aggregate minimum sentence which the relator then was undergoing, imposed by the courts of Philadelphia County. Judge Keller imposed a similar sentence on bill no. 27 to run concurrently with the sentence imposed on bill no. 26. Sentence was suspended on the second count of bill no. 24.
Upon this state of the record the sentence of Judge Keller would have been computed from March 5, 1958. On December 9, 1955, however, the sentence imposed by Judge McDevitt was commuted by the pardon board from a minimum of 10 years to a minimum of 7 years, 10 months, 9 . days so that the minimum sentence expired on December 19, 1955. The parole board on December 31, 1955, established January 4, 1956, as the release date for relator on his Philadelphia sentence, subject to the detainer for reentry to serve the sentence imposed by President Judge Hiram H. Keller. He therefore commenced serving his Bucks County sentence on January 4, 1956, and is presently incarcerated under that sentence.
Relator presented a petition for writ of habeas corpus in propria persona upon which a rule to show cause was issued, to which an answer was filed by respondent. Thereafter the court directed that a hear*778ing be had for the purpose of permitting relator to present such testimony in support of his petition and such argument in support of the reasons set forth therein as might be pertinent and relevant. Relator contends that the sentence imposed by Judge Keller must be computed from February 14, 1948, the date on which he was first committed to Bucks County prison. He argues that his removal from Bucks County prison by the Philadelphia authorities to that jurisdiction was illegal and without warrant in law and that therefore he has been in the custody of the Bucks County authorities since February 14, 1948. This, notwithstanding the fact that he was then serving a sentence imposed for another crime committed in Philadelphia County, after submitting himself to the jurisdiction of the Philadelphia courts and entering a plea of guilty to the offenses with which he was charged. If this argument were accepted, the result would be to make the sentence of Judge Keller in Bucks County run concurrently with that of Judge McDevitt in Philadelphia County.
Relator cannot, at this time, raise the question of the impropriety or the illegality of his release by the Bucks County authorities to the Philadelphia authorities. This should have been done at the time of his transfer or at least prior to his plea of guilty in Philadelphia courts. Not only did he not do this, but he submitted himself to the jurisdiction of Philadelphia County and served the sentence imposed as modified by the pardon board on his application thereto. We are not concerned with the propriety of the Philadelphia sentence, since relator acquiesced therein, and raised no question as to its validity.
Relator’s argument that he was not in custody of the Philadelphia authorities while serving the sentence imposed by Judge McDevitt, but on the contrary was still imprisoned under his original commitment by the *779Bucks County authorities on February 14, 1948, falls of its own weight. He was brought back to Bucks County from the Eastern State Penitentiary for trial on a writ of habeas corpus ad testificandum. This writ does not take the custody of the party who is desired to be brought into court from the custody of the person or institution to which he has been committed. Although produced in court, he is still in charge of the warden or other officer who is designated as his custodian: Commonwealth ex rel. v. Rotan, 82 Superior Ct. 172, 176.
Relator also contends that under the Act of May 28, 1937, P. L. 1036, 19 PS §894 et seq., his Bucks County sentence must be computed from February 16, 1948. The act provides as follows:
“Section 1. From and after the passage of this Act, all sentences for criminal offenses of persons who at the time sentence is imposed are held in custody in default of bail, or otherwise, shall begin to run and be computed from the date of commitment for the offense for which said sentence shall be imposed, unless the person sentenced shall then be undergoing imprisonment under a sentence imposed for any other offense or offenses, in which case the said sentence shall begin to run and be computed, either from the date of imposition thereof or from the expiration of such other sentence or sentences, as the Court shall, in its discretion, direct. (Italics supplied.)
“Section 2. The date of commitment referred to in section 1 of this Act, shall be the date of the last commitment for the offense for which the sentence is imposed.
“Section 3. If the sentence imposed shall be to any penitentiary or prison other than that in which the person sentenced shall have been held in custody, it shall be the duty of the Court to state in the sentence the date of commitment of such person.”
*780The Act of 1937, supra, was construed by the Superior Court in the case of Commonwealth ex rel. v. Burke, 162 Pa. Superior Ct. 592. The court held, at page 597, that “the expression ‘last commitment,’ as used in section 2 of the Act of May 28,1937, P. L. 1036, 19 PS §895, means that commitment which marks the commencement of the last period of actual imprisonment immediately preceding imposition of final sentence”. And, at page 598, the court held: “Sections 1 and 2 of the Act of 1937, 19 PS §§894, 895, make it clear that the period of imprisonment for which credit is to be given must be by reason of ‘the offense for which said sentence shall be imposed’.”
It is clear from the record that whatever confinement relator underwent as a result of the sentence of Judge McDevitt of Philadelphia County was by reason of a separate and distinct offense and it cannot be properly treated as a credit against imprisonment required by law with relatioh to the offense for which the relator was sentenced in Bucks County. It should be noted, however, that since the relator was imprisoned in Bucks County from February 14, 1948, to February 26, 1948, when he was released to the Philadelphia authorities, that he is entitled to a credit of the 12 days so served by him on the sentence imposed by Judge Keller. This is so because relator is entitled to a credit on his sentence for the period of actual imprisonment served by him in Bucks County before imposition of sentence: Commonwealth ex rel. v. Smith, 151 Pa. Superior Ct. 265; Commonwealth ex rel. v. Burke, supra.
Relator, in his petition, also refers to the fact that he expressed the desire to plead guilty to the charges before Justice of the Peace Gulick on February 16, 1948, and that he was prejudiced because immediate action was not taken by the authorities to have an indictment drawn and his plea of guilty taken forthwith. The prejudice averred is that had this been done *781promptly he would have been serving sentence on his plea of guilty before the Bucks County courts and could not have been taken to Philadelphia on February 26, 1948. He cites the Act of April 15, 1907, P. L. 62, as amended, 19 PS §241, which provides as follows:
“Whenever hereafter, within this Commonwealth, any person is charged with the commission of any crime, and such person is willing to waive an indictment by a grand jury, and shall notify the district attorney to that effect, no bill of indictment charging such offense shall be sent to a grand jury; but the district attorney shall at once prepare a bill of indictment, in the usual form, and the plea of guilty or not guilty, as the case may be, shall, at the request of the said defendant or defendant’s counsel be entered thereon, and the court of the proper county at any session thereof, shall thereupon, if the plea is guilty, forthwith, impose sentence for the offense set forth therein, and, if the plea is not guilty, bring the defendant to a speedy trial with or without a jury as provided by law; Provided, however, That nothing in this act shall be construed so as to relate to, or change the proceedings in, homicide cases in this Commonwealth: And provided further, That the defendant may withdraw his plea of guilty, at any time before sentence, by leave of the court.”
The district attorney was not notified by relator of his desire to plead guilty and the transcripts were not returned to the court by Justice of Peace Gulick until March 22, 1948, at which time relator was no longer in Bucks County. As already noted, the relator changed his mind and in fact pleaded “not guilty” in May of 1950 when he was arraigned before Judge Keller in Bucks County. The purpose of the Act of 1907, as amended, is to save the time and expense of indictment by a grand jury so that a speedy trial and sentence, or plea of guilty, as the case may be, can be had without a bill of indictment being presented to the *782grand jury. The act was not intended to serve the purpose contended for by the relator.
The relator is properly confined under the sentence of Judge Keller, but must be given credit for the 12 days which the relator spent in Bucks County prison from February 14 to February 26, 1948, awaiting trial on his Bucks County offenses.
Order
And now, this June 29,1956, the court orders and directs that the relator, Edward Fox, be allowed a credit of 12 days on the sentence of not less than five years nor more than 10 years imposed by Judge Keller.
The petition for writ of habeas corpus is refused and the rule granted thereon is discharged.