I suspect that the system never really thought through that far; so it is a bug, but nobody would 'expect' anything.
Try leaving ADE, editing the file mainfest.xml (probably in your My Digital Editions directory) and removing any sections that reference the book:
remove everything from and including <de:contentRecord> to and including </de:contentRecord> for the book.
... Oh, and delete any copies of the .epub file as well before you retry.
Then restart ADE and try the .acsm file for the second library again.
Thanks, but that's the first thing I tried and it didn't work. In case I missed something, I even tried again on a computer that did not have ADE on it, installing a fresh copy before downloading the .ascm. Same problem, which makes me think the issue is in the license server or Overdrive. Overdrive still thinks I have the book checked out at library B, so my money's on the license server.
Could well be. I don't know how centralized the license server is between different libraries; and how it manages the relationship between loans and books and people.