Pushing with an overcard + inside straight + flush draw is the right play. In this instance if you get HU with the QQ...

pokenum -h ah 9h - qh qs -- 6d th 7h
Holdem Hi: 990 enumerated boards containing 6d Th 7h
cards win %win lose %lose tie %tie EV
Ah 9h 509 51.41 472 47.68 9 0.91 0.519
Qs Qh 472 47.68 509 51.41 9 0.91 0.481

even if not, the equity you need in this spot to break even is 33.3% and you have just over 48%

pokenum -h ah 9h - qh qs - 8d 5c -- 6d th 7h
Holdem Hi: 903 enumerated boards containing 6d Th 7h
cards win %win lose %lose tie %tie EV
Ah 9h 434 48.06 463 51.27 6 0.66 0.483
Qs Qh 285 31.56 612 67.77 6 0.66 0.318
5c 8d 178 19.71 719 79.62 6 0.66 0.199