Appellant served time in jail for a domestic violence offense from January 17 to September 14, 2003, and was then released on probation. In November he was charged with new offenses, and his probation was revoked. While in custody, he was charged with assaulting another inmate. He was found guilty of the November offenses, and a negotiated disposition was reached for all three criminal cases. In calculating custody credits, the court divided the periods of incarceration into three phases, the second phase beginning on the arrest for the November offenses and continuing to the date of the inmate assault. On appeal, Gonzalez challenged the court’s allocation of presentence custody credits for his second phase to the domestic violence case only. The appellate court reversed and remanded. Under Penal Code section 2900.5, credits shall be given only when attributed to proceedings related to the same conduct for which the defendant has been convicted. Appellant’s custody time for the second phase was based both on the domestic violence and the new November offenses, but the credits were only awarded to the domestic violence case. Once the few days left to complete that sentence were credited, the remaining time should have been allocated to the November offenses. To hold otherwise would result in “dead time” not attributable to any offense. Note – the opinion criticized trial counsel for failing to brief the issue in the trial court and give the sentencing judge an opportunity to address it, rather than relying on the “costly and time-consuming appellate process” to resolve it.