mirror of https://github.com/ollama/ollama.git
				
				
				
			
		
			
	
	
		
			17 lines
		
	
	
		
			226 B
		
	
	
	
		
			Go
		
	
	
	
		
		
			
		
	
	
			17 lines
		
	
	
		
			226 B
		
	
	
	
		
			Go
		
	
	
	
|  | package server | ||
|  | 
 | ||
|  | import ( | ||
|  | 	"os" | ||
|  | 
 | ||
|  | 	"golang.org/x/sys/windows" | ||
|  | ) | ||
|  | 
 | ||
|  | func setSparse(file *os.File) error { | ||
|  | 	return windows.DeviceIoControl( | ||
|  | 		windows.Handle(file.Fd()), windows.FSCTL_SET_SPARSE, | ||
|  | 		nil, 0, | ||
|  | 		nil, 0, | ||
|  | 		nil, nil, | ||
|  | 	) | ||
|  | } |