you are not in problem
According to the law, large scale distribution of copyright works without permit from copyright owner (to resell used books is kind of distribution) is against the law, It is infringe of copyright law code. However,selling your own used book is far away from crim. At first, you didn't make profit. Secondly, infringe of copyright law was defined as large scale copies and distribution. Be careful, 10 copies of books is large scale. Ebay, Amazon, and bookstores might have contract with Press, So they can sell big scale of books. Libraries can sell used book because the books pass copyright protect preiod (10y).