>>72
aiの最後にnull文字は入れないの?
入れないなら
srd::string str { ai, sizeof(ai)/sizeof(ai[0]) };