Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
New Contributor I
8 Views

CHDIR

I wrote this as a simple program and it works fine - although it prefere IFPORT - now as a routine in WLF I get an access code violaton on run 

​Life is a long beach and the life guard is always at the other end
    
!      ****************************************************************
!     
      subroutine chdirA(i)
!
!      ****************************************************************
      
      use IFPOSIX
      implicit none


      CHARACTER(len=255) :: path
      integer i,ilen, ierror
    
    
      CALL PXFGETCWD (path,ilen,ierror)
      WRITE(*,*) TRIM(path)
      call PXFCHDIR("C:\",3,i)
      call PXFCHDIR("users\macne\documents\Visual Studio 2013\Projects\Program070 - Beams\Lothurr",76,i)
       write(*,*)i
       CALL PXFGETCWD (path,ilen,ierror)
       WRITE(*,*) TRIM(path)
       return 
       end subroutine

 

0 Kudos
2 Replies
Highlighted
New Contributor I
8 Views

It crashed in WULF as a

It crashed in WULF as a subroutine - with access code violation at the first chdir

0 Kudos
Highlighted
8 Views

It seems evident to me that

It seems evident to me that your WULF program has issues with stack corruption. I doubt this CHDIR routine is relevant. I can reproduce the stack corruption (from your other thread) but it may take me a while to track down.

Retired 12/31/2016
0 Kudos