Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
459 B

  1. #Test for passing of null values. Note that
  2. # currently it is not possible to pass a null into
  3. # COM, but one can get a null out of COM.
  4. use OLE;
  5. use Win32;
  6. # Get a favorite class from CIMOM
  7. $locator = CreateObject OLE 'WbemScripting.SWbemLocator';
  8. $service = $locator->ConnectServer (".", "root/default");
  9. $class = $service->Get("a");
  10. if (!defined($class->{pnull})) {
  11. print "not defined\n";
  12. }
  13. else {
  14. print "defined\n";
  15. }