Thanks for the replies. It would have to be separate PNRs for the illegal connection reason stated above.
This is a tough one. To play it safe means spending the night in a hotel and taking the first flight out in the morning. I'm the type of person where once I start a trip I just want to get to where I'm going. And it looks like the UA flight at 22:35 is the last flight out of LAX to SFO. Oh well. I'll have to think about it some more.
I realize that I could easily take other airlines and what not, but what I like about THAI is how they have low fares for economy and premium economy that earn me 150% elite qualification miles on CO. (Low in comparison to when I fly SFO-EWR to go home a few times a year on CO, pay ~$500 and get 5000 elite miles. So on THAI I'd pay ~3x and earn 5x elite miles)