本文整理汇总了C++中FSString::SetSys方法的典型用法代码示例。如果您正苦于以下问题:C++ FSString::SetSys方法的具体用法?C++ FSString::SetSys怎么用?C++ FSString::SetSys使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FSString
的用法示例。
在下文中一共展示了FSString::SetSys方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: StrError
FSString FSSys::StrError( int err )
{
sys_char_t buf[1024];
FSString ret;
ret.SetSys( sys_error_str( err, buf, 0x100 ) );
return ret;
}
示例2: FSString
FSString FSWin32Net::StrError( int err )
{
if ( err == ERRNOSUPPORT )
{
return FSString( "Operation not supported by net fs" );
}
FSString ret;
sys_char_t buf[1024];
ret.SetSys( sys_error_str( err, buf, 0x100 ) );
return ret;
}
示例3: StrError
//.........这里部分代码省略.........
case LIBSSH2_ERROR_INVAL:
s = "LIBSSH2_ERROR_INVAL";
break;
case LIBSSH2_ERROR_INVALID_POLL_TYPE:
s = "LIBSSH2_ERROR_INVALID_POLL_TYPE";
break;
case LIBSSH2_ERROR_PUBLICKEY_PROTOCOL:
s = "LIBSSH2_ERROR_PUBLICKEY_PROTOCOL";
break;
case LIBSSH2_ERROR_EAGAIN:
s = "LIBSSH2_ERROR_EAGAIN";
break;
case LIBSSH2_ERROR_BUFFER_TOO_SMALL:
s = "LIBSSH2_ERROR_BUFFER_TOO_SMALL";
break;
case LIBSSH2_ERROR_BAD_USE:
s = "LIBSSH2_ERROR_BAD_USE";
break;
case LIBSSH2_ERROR_COMPRESS:
s = "LIBSSH2_ERROR_COMPRESS";
break;
case LIBSSH2_ERROR_OUT_OF_BOUNDARY:
s = "LIBSSH2_ERROR_OUT_OF_BOUNDARY";
break;
case LIBSSH2_ERROR_AGENT_PROTOCOL:
s = "LIBSSH2_ERROR_AGENT_PROTOCOL";
break;
case LIBSSH2_ERROR_SOCKET_RECV:
s = "LIBSSH2_ERROR_SOCKET_RECV";
break;
case LIBSSH2_ERROR_ENCRYPT:
s = "LIBSSH2_ERROR_ENCRYPT";
break;
case LIBSSH2_ERROR_BAD_SOCKET:
s = "LIBSSH2_ERROR_BAD_SOCKET";
break;
default:
s = "LIBSSH2_ERROR_???";
break;
}
}
else
{
switch ( err )
{
case SSH_INTERROR_NOTSUPPORT:
s = "not supported operation";
break;
case SSH_INTERROR_X3:
s = "X3";
break;
case SSH_INTERROR_CONNECT:
s = "connection failed";
break;
case SSH_INTERROR_AUTH:
s = "authorization failed";
break;
case SSH_INTERROR_FATAL:
s = "fatal ssh error";
break;
case SSH_INTERROR_STOPPED:
s = "Process stopped";
break;
default:
if ( err >= 0 )
{
sys_char_t buf[0x100];
FSString str;
str.SetSys( sys_error_str( err, buf, 0x100 ) );
return str;
}
char buf[0x100];
snprintf( buf, sizeof( buf ), "err : %i ???", err );
FSString str( CS_UTF8, buf );
return str;
}
}
return FSString( CS_UTF8, s );
}