Article View: comp.os.msdos.programmer
Article #5807Re: Notice diskchange
From: Fridrik Skulason
Date: Tue, 16 Apr 1991 21:48
Date: Tue, 16 Apr 1991 21:48
33 lines
1536 bytes
1536 bytes
In article <CMM.0.90.2.671783143.sverrehu@helblinde.ifi.uio.no> sverrehu@ifi.uio.no (Sverre H Huseby) writes: >How can I make my program aware that a diskette >has been removed from a drive, and a new one >inserted instead? Hm - I was looking at a related problem - how to make my virus scanner automatically scan all diskettes inserted, and here is the conclusion I reached: On a PC (or PCjr) you simply cannot do this - there is no way to know if the diskette has been replaced with an identical one. On most XTs, all ATs, '386 etc.... it is fairly easy... MOV DL, drive MOV AH,16H INT 13H CMP AH,6 JE diskette_changed Either do this in the timer interrupt (if you are not in the INT 13H routine at the moment), or intercept INT 13H, and do this before doing any reads/writes... See the interrupt list from Ralf Brown for further information. -frisk Fridrik Skulason University of Iceland | Technical Editor of the Virus Bulletin (UK) | Reserved for future expansion E-Mail: frisk@rhi.hi.is Fax: 354-1-28801 |
Technical Details
Message-ID:
<3052@krafla.rhi.hi.is>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!rice!uupsi!sunic!isgate!krafla!friskReferences:
<CMM.0.90.2.671783143.sverrehu@helblinde.ifi.uio.no>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!rice!uupsi!sunic!isgate!krafla!frisk From: frisk@rhi.hi.is (Fridrik Skulason) Newsgroups: comp.os.msdos.programmer Subject: Re: Notice diskchange Message-ID: <3052@krafla.rhi.hi.is> Date: 16 Apr 91 21:48:15 GMT References: <CMM.0.90.2.671783143.sverrehu@helblinde.ifi.uio.no> Reply-To: frisk@rhi.hi.is (Fridrik Skulason) Organization: University of Iceland (RHI) Lines: 33