mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 09:02:43 +00:00 
			
		
		
		
	Kernel: Replace all usages of String::number with KString::number
This commit is contained in:
		
							parent
							
								
									aa1f7060af
								
							
						
					
					
						commit
						a4560313eb
					
				
					 2 changed files with 3 additions and 2 deletions
				
			
		|  | @ -170,7 +170,7 @@ UNMAP_AFTER_INIT void SysFSUSBBusDirectory::initialize() | ||||||
| 
 | 
 | ||||||
| ErrorOr<NonnullRefPtr<SysFSUSBDeviceInformation>> SysFSUSBDeviceInformation::create(USB::Device& device) | ErrorOr<NonnullRefPtr<SysFSUSBDeviceInformation>> SysFSUSBDeviceInformation::create(USB::Device& device) | ||||||
| { | { | ||||||
|     auto device_name = TRY(KString::try_create(String::number(device.address()))); |     auto device_name = TRY(KString::number(device.address())); | ||||||
|     return adopt_nonnull_ref_or_enomem(new (nothrow) SysFSUSBDeviceInformation(move(device_name), device)); |     return adopt_nonnull_ref_or_enomem(new (nothrow) SysFSUSBDeviceInformation(move(device_name), device)); | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -51,7 +51,8 @@ ErrorOr<void> Process::traverse_stacks_directory(FileSystemID fsid, Function<Err | ||||||
|         for (auto const& thread : list) { |         for (auto const& thread : list) { | ||||||
|             int tid = thread.tid().value(); |             int tid = thread.tid().value(); | ||||||
|             InodeIdentifier identifier = { fsid, SegmentedProcFSIndex::build_segmented_index_for_thread_stack(pid(), thread.tid()) }; |             InodeIdentifier identifier = { fsid, SegmentedProcFSIndex::build_segmented_index_for_thread_stack(pid(), thread.tid()) }; | ||||||
|             TRY(callback({ String::number(tid), identifier, 0 })); |             auto name = TRY(KString::number(tid)); | ||||||
|  |             TRY(callback({ name->view(), identifier, 0 })); | ||||||
|         } |         } | ||||||
|         return {}; |         return {}; | ||||||
|     }); |     }); | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Idan Horowitz
						Idan Horowitz