Random: Mark getRandom* const
这个提交包含在:
		@@ -29,7 +29,7 @@ Random::Random()
 | 
			
		||||
{
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
std::vector<char> Random::getRandom(unsigned int bytes)
 | 
			
		||||
std::vector<char> Random::getRandom(unsigned int bytes) const
 | 
			
		||||
{
 | 
			
		||||
	auto buffer = std::make_unique<char[]>(bytes);
 | 
			
		||||
	int r = getrandom(buffer.get(), bytes, GRND_NONBLOCK);
 | 
			
		||||
@@ -46,7 +46,7 @@ std::vector<char> Random::getRandom(unsigned int bytes)
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
std::string Random::getRandomHexString(unsigned int bytes)
 | 
			
		||||
std::string Random::getRandomHexString(unsigned int bytes) const
 | 
			
		||||
{
 | 
			
		||||
	std::stringstream stream;
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										4
									
								
								random.h
									
									
									
									
									
								
							
							
						
						
									
										4
									
								
								random.h
									
									
									
									
									
								
							@@ -22,8 +22,8 @@ class Random
 | 
			
		||||
{
 | 
			
		||||
  public:
 | 
			
		||||
	Random();
 | 
			
		||||
	std::string getRandomHexString(unsigned int bytes);
 | 
			
		||||
	std::vector<char> getRandom(unsigned int bytes);
 | 
			
		||||
	std::string getRandomHexString(unsigned int bytes) const;
 | 
			
		||||
	std::vector<char> getRandom(unsigned int bytes) const;
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
#endif // RANDOM_H
 | 
			
		||||
 
 | 
			
		||||
		在新工单中引用
	
	屏蔽一个用户