Yes, it's a cordyline.
It's not poisonous to buns. After my buns had decimated my garden last year I spent some time researching plants that were not poisonous to buns but which they would not eat. Cordylines were plants that were recommended.
So I bought some, planted them up and the buns ...... ate them! :shock:
It didn't do them any harm - the buns that is - the cordylines are no more.
As for geraniums - real geraniums are not harmful to buns and they love to eat them. However, the plants that tend to be called geraniums, which are actually pelargoniums are not recommended for buns.