40+ results for 'php opendir' (0 ms)

Not the results you expected?

view.php (https://bitbucket.org/tumivn/phpexamples.git) PHP · 437 lines

1 <?php

2 /**

3 *

4 * @View Class

5 *

6 * @copyright Copyright (C) 2009 PHPRO.ORG. All rights reserved.

7 *

8 * @license new bsd http://www.opensource.org/licenses/bsd-license.php

398 $deleteDir = realpath($dir);

399

400 if ($handle = opendir($deleteDir))

401 {

402 while (false !== ($file = readdir($handle)))

theme.php (https://gitlab.com/x33n/respond) PHP · 363 lines

1 <?php

2

3 /**

16

17 // open themes direcotry

18 if($handle = opendir(APP_LOCATION.THEMES_FOLDER)){

19

20 $blacklist = array('.', '..');

files.php (https://gitlab.com/webbroteam/satisfaction-mvc) PHP · 306 lines

8 * For full copyright and license information, please see the docs/CREDITS.txt file.

9 *

10 * @author Khoa Bui (khoaofgod) <khoaofgod@gmail.com> http://www.phpfastcache.com

11 * @author Georges.L (Geolim4) <contact@geolim4.com>

12 *

13 */

14

15 namespace phpFastCache\Drivers;

16

17 use phpFastCache\Core\DriverAbstract;

18 use phpFastCache\Exceptions\phpFastCacheDriverException;

19

20 /**

57 * @param bool $skip

58 * @return string

59 * @throws phpFastCacheDriverException

60 */

61 private function getFilePath($keyword, $skip = false)

QpContentEncoderAcceptanceTest.php (https://gitlab.com/techniconline/kmc) PHP · 156 lines

1 <?php

2

3 class Swift_Mime_ContentEncoder_QpContentEncoderAcceptanceTest extends \PHPUnit_Framework_TestCase

14 public function testEncodingAndDecodingSamples()

15 {

16 $sampleFp = opendir($this->_samplesDir);

17 while (false !== $encodingDir = readdir($sampleFp)) {

18 if (substr($encodingDir, 0, 1) == '.') {

28

29 if (is_dir($sampleDir)) {

30 $fileFp = opendir($sampleDir);

31 while (false !== $sampleFile = readdir($fileFp)) {

32 if (substr($sampleFile, 0, 1) == '.') {

61 public function testEncodingAndDecodingSamplesFromDiConfiguredInstance()

62 {

63 $sampleFp = opendir($this->_samplesDir);

64 while (false !== $encodingDir = readdir($sampleFp)) {

65 if (substr($encodingDir, 0, 1) == '.') {

FsExplorer.class.php (https://github.com/midnightskinhead/tubepress.git) PHP · 297 lines

1 <?php

2 /**

3 * Copyright 2006 - 2011 Eric D. Hough (http://ehough.com)

20 */

21

22 class_exists('org_tubepress_impl_classloader_ClassLoader') || require dirname(__FILE__) . '/../classloader/ClassLoader.class.php';

23 org_tubepress_impl_classloader_ClassLoader::loadClasses(array(

24 'org_tubepress_api_filesystem_Explorer',

74

75 $toReturn = array();

76 if ($handle = opendir($dir)) {

77

78 while (($file = readdir($handle)) !== false) {

119

120 $toReturn = array();

121 if ($handle = opendir($dir)) {

122

123 while (($file = readdir($handle)) !== false) {

Directory.cxx (https://github.com/chrismullins/ITK.git) C++ · 253 lines

206 /* There is a problem with the Portland compiler, large file

207 support and glibc/Linux system headers:

208 http://www.pgroup.com/userforum/viewtopic.php?

209 p=1992&sid=f16167f51964f1a68fe5041b8eb213b6

210 */

220 this->Clear();

221

222 DIR* dir = opendir(name.c_str());

223

224 if (!dir)

238 unsigned long Directory::GetNumberOfFilesInDirectory(const kwsys_stl::string& name)

239 {

240 DIR* dir = opendir(name.c_str());

241

242 unsigned long count = 0;

eva_geometrie_administrations.php (https://bitbucket.org/pombredanne/spip-zone-treemap.git) PHP · 160 lines

1 <?php

2 function eva_geometrie_install($action){

3

9 //Pour les collègues matheux, on insères ici quelques formats de documents à accepter par SPIP pour le logiciel Scilab

10 //Ajout de l'icone pour le format sce pour Scilab

11 if (!@opendir(_DIR_IMG."icones")) {mkdir(_DIR_IMG."icones");}

12 if (!@fopen(_DIR_IMG."icones/sce.png", "r")) {copy(_DIR_PLUGIN_EVA_GEOMETRIE.'img_pack/sce.png',_DIR_IMG.'icones/sce.png');}

13 //On poursuit avec l'ajout du format sce dans la base de données

108 $test5_ta=sql_fetch($test5_req);

109 $test5=$test5_ta['inclus'];

110 if ((!@opendir(_DIR_IMG."icones")) OR (!@fopen(_DIR_IMG."icones/ggb.png", "r")) OR (!@fopen(_DIR_IMG."icones/glb.png", "r")) OR (!@fopen(_DIR_IMG."icones/gxt.png", "r")) OR (!@fopen(_DIR_IMG."icones/zir.png", "r")) OR (!@fopen(_DIR_IMG."icones/zirs.png", "r")) OR !$test OR !$test2 OR !$test3 OR !$test4 OR !$test5) {return false;}

111 else {return true;}

112 }

114

115 case 'install':

116 if (!@opendir(_DIR_IMG."icones")) {mkdir(_DIR_IMG."icones");}

117 if (!@fopen(_DIR_IMG."icones/ggb.png", "r")) {copy(_DIR_PLUGIN_EVA_GEOMETRIE.'img_pack/ggb.png',_DIR_IMG.'icones/ggb.png');}

118 if (!@fopen(_DIR_IMG."icones/glb.png", "r")) {copy(_DIR_PLUGIN_EVA_GEOMETRIE.'img_pack/glb.png',_DIR_IMG.'icones/glb.png');}

PhpStreamWrapperInterface.php (https://gitlab.com/geeta7/drupal) PHP · 228 lines

11 * Defines a generic PHP stream wrapper interface.

12 *

13 * @see http://www.php.net/manual/class.streamwrapper.php

14 */

15 interface PhpStreamWrapperInterface {

65 *

66 * @see stream_select()

67 * @see http://php.net/manual/streamwrapper.stream-cast.php

68 */

69 public function stream_cast($cast_as);

117 * implemented, FALSE should be returned.

118 *

119 * @see http://www.php.net/manual/streamwrapper.stream-metadata.php

120 */

121 public function stream_metadata($path, $option, $value);

backupTenant.php (https://github.com/ciniki/core.git) PHP · 186 lines

1 <?php

2 //

3 // Description

139 // Note: Due to sshfs mount problems at rackspace, the following code was added to create backups on local storage and then copy via sftp.

140 // In ciniki-api.ini setup final_backup_dir = ssh2.sftp://user:pass@ftpserver:22/fullpathtobackups

141 // Must have libssh2-php installed as a package on server

142 //

143 if( isset($final_backup_dir) ) {

160 $zip_backup_dir = $final_backup_dir;

161 }

162 $dh = opendir($zip_backup_dir);

163 $today = date('Ymd');

164 $today_datetime = strtotime($today);

worktree.c (https://gitlab.com/181gaming/git) C · 303 lines

183

184 strbuf_addf(&path, "%s/worktrees", get_git_common_dir());

185 dir = opendir(path.buf);

186 strbuf_release(&path);

187 if (dir) {

Cache_File.php (https://gitlab.com/karlen/ayo_wp) PHP · 455 lines

1 <?php

2 namespace W3TC;

3

116 $expires_at = time() + $expire;

117 @fputs( $fp, pack( 'L', $expires_at ) );

118 @fputs( $fp, '<?php exit; ?>' );

119 @fputs( $fp, @serialize( $var ) );

120 @fclose( $fp );

314 $hash = md5( $key );

315

316 $path = sprintf( '%s/%s/%s.php', substr( $hash, 0, 3 ), substr( $hash, 3, 3 ), $hash );

317

318 return $path;

333

334 private function dirsize( $path, $size, $timeout_time ) {

335 $dir = @opendir( $path );

336

337 if ( $dir ) {

mf_install.php (https://github.com/leocaseiro/Magic-Fields-2.git) PHP · 212 lines

1 <?php

2 /**

3 * This file content the routines for install/activate uninstall/deactivate Magic Fields

8 global $wpdb;

9

10 require_once(ABSPATH.'wp-admin/includes/upgrade.php');

11

12 // Get collation info

149 public function clear_cache(){

150 if (is_dir(MF_CACHE_DIR)) {

151 if ($dh = opendir(MF_CACHE_DIR)) {

152 while (($file = readdir($dh)) !== false) {

153 if(!is_dir($file) && !in_array($file,array('.','..','.DS_Store') ) ){

162 public function delete_files(){

163 if (is_dir(MF_FILES_DIR)) {

164 if ($dh = opendir(MF_FILES_DIR)) {

165 while (($file = readdir($dh)) !== false) {

166 if(!is_dir($file) && !in_array($file,array('.','..','.DS_Store') ) ){

FsExplorer.class.php (https://gitlab.com/endomorphosis/jeffersonsmithmayor) PHP · 297 lines

1 <?php

2 /**

3 * Copyright 2006 - 2012 Eric D. Hough (http://ehough.com)

20 */

21

22 class_exists('org_tubepress_impl_classloader_ClassLoader') || require dirname(__FILE__) . '/../classloader/ClassLoader.class.php';

23 org_tubepress_impl_classloader_ClassLoader::loadClasses(array(

24 'org_tubepress_api_filesystem_Explorer',

74

75 $toReturn = array();

76 if ($handle = opendir($dir)) {

77

78 while (($file = readdir($handle)) !== false) {

119

120 $toReturn = array();

121 if ($handle = opendir($dir)) {

122

123 while (($file = readdir($handle)) !== false) {

list_functions.php (https://gitlab.com/endomorphosis/fusenews) PHP · 127 lines

1 <?php

2

3 function list_jumps() {

4 global $phpiCal_config, $lang, $cal;

5 $calName = join(',', array_map("getCalendarName", split(',', $cal)));

6 $today = date('Ymd', time() + $phpiCal_config->second_offset);

7 $return = '<option value="#">'.$lang['l_jump'].'</option>';

8 $return .= '<option value="day.php?cal='.$calName.'&amp;getdate='.$today.'">'.$lang['l_goday'].'</option>';

9 $return .= '<option value="week.php?cal='.$calName.'&amp;getdate='.$today.'">'.$lang['l_goweek'].'</option>';

10 $return .= '<option value="month.php?cal='.$calName.'&amp;getdate='.$today.'">'.$lang['l_gomonth'].'</option>';

11 $return .= '<option value="year.php?cal='.$calName.'&amp;getdate='.$today.'">'.$lang['l_goyear'].'</option>';

MaildirMessageOldTest.php (https://bitbucket.org/Dal-Papa/is-340-publish-base.git) PHP · 192 lines

1 <?php

2 /**

3 * Zend Framework

18 * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)

19 * @license http://framework.zend.com/license/new-bsd New BSD License

20 * @version $Id: MaildirMessageOldTest.php 24593 2012-01-05 20:35:02Z matthew $

21 */

22

24 * Zend_Mail_Storage_Maildir

25 */

26 require_once 'Zend/Mail/Storage/Maildir.php';

27

28 /**

29 * Zend_Config

30 */

31 require_once 'Zend/Config.php';

32

33 /**

index.php (https://gitlab.com/novadeviator/distrokid-analytics) PHP · 226 lines

57

58

59 <?php

60

61 $dir = "tsv/"; // you can change this folder. it where tsv reports live

63 // open directory, and read its contents

64 if (is_dir($dir)) {

65 if ($dh = opendir($dir)) {

66 while (($file = readdir($dh)) !== false) {

67 if ($file != ".") {

104

105 // include misspellings group file, if it exists

106 //$groups = "groups.php";

107 //file_exists($groups) AND include $groups;

108

PackageScaffolderAbstract.php (https://bitbucket.org/Dal-Papa/is-340-publish-base.git) PHP · 249 lines

1 <?php

2 /**

3 * Zend Framework

48 return;

49 }

50 file_put_contents('php://stderr', $message . ($newLine ? "\r\n" : ''));

51 }

52

61 $this->deleteDirectory($path);

62 $phar->extractTo($path);

63 @unlink($path . '/index.php');

64 @unlink($path . '/build.bat');

65 $this->copyDirectory($path . '/resources', $path, false);

213 $handleDir = false;

214 if (is_dir($path) ) {

215 $handleDir = @opendir($path);

216 }

217 if (!$handleDir) {

rsform.class.php (https://github.com/shafiqissani/Jewelery-Ecommerce-.git) PHP · 175 lines

1 <?php

2 /**

3 * @version 1.2.0

14 ///////////////////////////////////////////////////// SUBMISSIONS /////////////////////////////////////////////////////

15

16 include('submissions.class.php');

17

18 ///////////////////////////////////////////////////// CAPTCHA /////////////////////////////////////////////////////

19

20 include('captcha.class.php');

21

22 ///////////////////////////////////////////////////// RSINSTALLER /////////////////////////////////////////////////////

68 if (eregi( '.zip$', $archivename )) {

69 // Extract functions

70 require_once( $RSadapter->config['absolute_path'] . '/administrator/includes/pcl/pclzip.lib.php' );

71 require_once( $RSadapter->config['absolute_path'] . '/administrator/includes/pcl/pclerror.lib.php' );

MaildirMessageOldTest.php (https://github.com/nbcutech/o3drupal.git) PHP · 192 lines

1 <?php

2 /**

3 * Zend Framework

18 * @copyright Copyright (c) 2005-2011 Zend Technologies USA Inc. (http://www.zend.com)

19 * @license http://framework.zend.com/license/new-bsd New BSD License

20 * @version $Id: MaildirMessageOldTest.php 23775 2011-03-01 17:25:24Z ralph $

21 */

22

24 * Zend_Mail_Storage_Maildir

25 */

26 require_once 'Zend/Mail/Storage/Maildir.php';

27

28 /**

29 * Zend_Config

30 */

31 require_once 'Zend/Config.php';

32

33 /**

theme.class.php (https://github.com/Arkadiy-Sedelnikov/joostina-1.4.git) PHP · 524 lines

1 <?php

2 /**

3 * SPAW Editor v.2 Theme classes

9 */

10

11 require_once(str_replace('\\\\', '/', dirname(__FILE__)) . '/config.class.php');

12

13 /**

431 if(is_dir($pgdir)){

432 // load theme settings

433 if($dh = opendir($pgdir)){

434 while(($pg = readdir($dh)) !== false){

435 if(file_exists($pgdir . $pg . '/lib/theme/' . $this->name . '/config/theme.config.php')){

436 // load theme config file for each plugin

437 include($pgdir . $pg . '/lib/theme/' . $this->name . '/config/theme.config.php');

438 // load default styles for "core" only

439 if($pg == "core"){

caffiche_graphe.php (https://github.com/gmarchault/GmdGraphe.git) PHP · 232 lines

1 <?php

2

3 class CAffiche_graphe

58 if ( @is_dir($this->path_web) )

59 {

60 if ( $dh=@opendir($this->path_web) )

61 {

62 while ( ($filee=@readdir($dh))!==false )

154 if ( @is_dir($this->path_web) )

155 {

156 if ( $dh=@opendir($this->path_web) )

157 {

158 while ( ($filee=@readdir($dh))!==false )

206 if ( @is_dir($this->path_web) )

207 {

208 if ( $dh=@opendir($this->path_web) )

209 {

210 while ( ($filee=@readdir($dh))!==false )

changed10.c (https://github.com/Milkyway-at-home/nemo.git) C · 209 lines

166 dev = st.st_dev;

167

168 if ( (dirp = opendir(dir)) == NULL) {

169 fprintf(stderr, "%s: cannot open directory %s\n", progname, dir);

170 exit(1);

GetFiles.php (https://github.com/staunchRobots/Symfony-Groovy-Ecom.git) PHP · 128 lines

1 <?php

2 /*

3 * CKFinder

21 * Include base XML command handler

22 */

23 require_once CKFINDER_CONNECTOR_LIB_DIR . "/CommandHandler/XmlCommandHandlerBase.php";

24

25 /**

66 $thumbFiles = array();

67

68 if ($dh = @opendir($_sServerDir)) {

69 while (($file = readdir($dh)) !== false) {

70 if ($file != "." && $file != ".." && !is_dir($_sServerDir . $file)) {

buildPackagesArray.php (https://bitbucket.org/valmy/openx.git) PHP · 123 lines

1 <?php

2

3 /*

56 }

57 $aVersions = array();

58 $dh = opendir($readPath);

59 if ($dh)

60 {

ubr_get_progress.php (https://gitlab.com/ppapadatis/Videolearn) PHP · 113 lines

1 <?php

2 //******************************************************************************************************

3 // ATTENTION: THIS FILE HEADER MUST REMAIN INTACT. DO NOT DELETE OR MODIFY THIS FILE HEADER.

4 //

5 // Name: ubr_get_progress.php

6 // Revision: 1.2

7 // Date: 2/18/2008 5:37:18 PM

24

25 //***************************************************************************************************************

26 // * ATTENTION * If you need to debug this file, set the $DEBUG_AJAX = 1 in ubr_ini.php

27 // and use the showDebugMessage function. eg. showDebugMessage("Upload ID = $UPLOAD_ID<br>");

28 //***************************************************************************************************************

38 $UPLOAD_ID = ''; // Initialize upload id

39

40 require 'ubr_ini.php';

41 require 'ubr_lib.php';

svn.php (https://github.com/agallou/atoum.git) PHP · 354 lines

65 ->object($this->testedInstance->setRepositoryUrl($url = uniqid()))->isTestedInstance

66 ->string($this->testedInstance->getRepositoryUrl())->isEqualTo($url)

67 ->object($this->testedInstance->setRepositoryUrl($url = rand(- PHP_INT_MAX, PHP_INT_MAX)))->isTestedInstance

68 ->string($this->testedInstance->getRepositoryUrl())->isEqualTo((string) $url)

69 ;

93 ->object($this->testedInstance->setUsername($username = uniqid()))->isTestedInstance

94 ->string($this->testedInstance->getUsername())->isEqualTo($username)

95 ->object($this->testedInstance->setUsername($username = rand(- PHP_INT_MAX, PHP_INT_MAX)))->isTestedInstance

96 ->string($this->testedInstance->getUsername())->isEqualTo((string) $username)

97 ;

109 ->object($this->testedInstance->setPassword($password = uniqid()))->isTestedInstance

110 ->string($this->testedInstance->getPassword())->isEqualTo($password)

111 ->object($this->testedInstance->setPassword($password = rand(- PHP_INT_MAX, PHP_INT_MAX)))->isTestedInstance

112 ->string($this->testedInstance->getPassword())->isEqualTo((string) $password)

113 ;

syscalls.c (https://github.com/thentenaar/dc-load-ip.git) C · 365 lines

308 }

309

310 DIR * opendir(const char *name)

311 {

312 command_string_t * command = (command_string_t *)(pkt_buf + ETHER_H_LEN + IP_H_LEN + UDP_H_LEN);

313 int namelen = strlen(name);

314

315 memcpy(command->id, CMD_OPENDIR, 4);

316 memcpy(command->string, name, namelen+1);

317

maintain_backups.php (https://github.com/rhempen/cms.git) PHP · 135 lines

99 <table cellpadding="5" cellspacing="1" border="0" width="80%">

100 <tr class="navi_overview_titel">

101 <th width="30%"><?php echo $GLOBALS['BACKUP']['DATEI'];?></th>

102 <th width="30%"><?php echo $GLOBALS['BACKUP']['ERSTELLT'];?></th>

106 </tr>

107

108 <?php

109 foreach($fs as $index => $file) {

110 // Klasse, File mit Pfad, Extension

121 <tr class="<?php echo $class;?>">

122 <td><?php echo $file['datei']; ?></td>

123 <td align="right"><?php echo set_date_time($file['fmt']); ?></td>

125 <td align="center"><?php echo '<a href="'.$srcfile.'">'.$icon.'</a>'; ?></td>

126 <td align="center"><?php echo '<a href="'.$_SERVER['PHP_SELF'].'?act=delete&file='.$file['datei'].'"><img src="../gifs/delete.gif" alt="delete" title="delete" onclick="'.$jscript.'"' ?></td>

127 </tr>

128 <?php

svn.php (https://github.com/Yacodo/atoum.git) PHP · 411 lines

71 ->object($svn->setRepositoryUrl($url = uniqid()))->isIdenticalTo($svn)

72 ->string($svn->getRepositoryUrl())->isEqualTo($url)

73 ->object($svn->setRepositoryUrl($url = rand(- PHP_INT_MAX, PHP_INT_MAX)))->isIdenticalTo($svn)

74 ->string($svn->getRepositoryUrl())->isEqualTo((string) $url)

75 ;

101 ->object($svn->setUsername($username = uniqid()))->isIdenticalTo($svn)

102 ->string($svn->getUsername())->isEqualTo($username)

103 ->object($svn->setUsername($username = rand(- PHP_INT_MAX, PHP_INT_MAX)))->isIdenticalTo($svn)

104 ->string($svn->getUsername())->isEqualTo((string) $username)

105 ;

116 ->object($svn->setPassword($password = uniqid()))->isIdenticalTo($svn)

117 ->string($svn->getPassword())->isEqualTo($password)

118 ->object($svn->setPassword($password = rand(- PHP_INT_MAX, PHP_INT_MAX)))->isIdenticalTo($svn)

119 ->string($svn->getPassword())->isEqualTo((string) $password)

120 ;

perl.xml (https://jedit.svn.sourceforge.net/svnroot/jedit) XML · 604 lines

332 <KEYWORD3>mkdir</KEYWORD3>

333 <KEYWORD3>open</KEYWORD3>

334 <KEYWORD3>opendir</KEYWORD3>

335 <KEYWORD3>readlink</KEYWORD3>

336 <KEYWORD3>rename</KEYWORD3>

main.cc (https://freespeech.svn.sourceforge.net/svnroot/freespeech) C++ · 627 lines ✨ Summary

This C++ code creates a graphical user interface (GUI) application called “vflow” that displays multiple documents in a multi-document interface (MDI). It initializes the GUI, sets up event handling for segmentation faults, and starts the main loop to display the GUI. The application can be run with or without specifying a document path, and it loads the specified document if provided.

545 #include <signal.h>

546

547 //DIR *opendir (const char *name);

548

549

552 {

553 string path = "/home/jm/contrat/lib";

554 DIR *my_directory = opendir (path.c_str());

555 struct dirent *current_entry;

556 for (current_entry = readdir(my_directory);

php.xml (https://jedit.svn.sourceforge.net/svnroot/jedit) XML · 2590 lines

11 </PROPS>

12 <RULES IGNORE_CASE="TRUE">

13 <SPAN TYPE="MARKUP" DELEGATE="PHP">

14 <BEGIN>&lt;?php</BEGIN>

16 </SPAN>

17

18 <SPAN TYPE="MARKUP" DELEGATE="PHP">

19 <BEGIN>&lt;?</BEGIN>

20 <END>?&gt;</END>

21 </SPAN>

22

23 <SPAN TYPE="MARKUP" DELEGATE="PHP">

24 <BEGIN>&lt;%=</BEGIN>

25 <END>%&gt;</END>

64

65 <RULES SET="TAGS" DEFAULT="MARKUP">

66 <SPAN TYPE="MARKUP" DELEGATE="PHP">

67 <BEGIN>&lt;?php</BEGIN>

UnixFileSystem.php (git://github.com/alexgorbatchev/SyntaxHighlighter.git) text · 0 lines

1 <?php

2 /*

3 * $Id: UnixFileSystem.php 258 2007-10-21 00:46:45Z hans $

20 */

21

22 include_once 'phing/system/io/FileSystem.php';

23

24 /**

25 * UnixFileSystem class. This class encapsulates the basic file system functions

26 * for platforms using the unix (posix)-stylish filesystem. It wraps php native

27 * functions suppressing normal PHP error reporting and instead uses Exception

29 *

30 * This class is part of a oop based filesystem abstraction and targeted to run

31 * on all supported php platforms.

32 *

33 * Note: For debugging turn track_errors on in the php.ini. The error messages

linux.c (https://libusb.svn.sourceforge.net/svnroot/libusb) C · 734 lines ✨ Summary

This C code is part of a USB device driver implementation for Linux. It initializes and manages USB devices, including finding the virtual filesystem path, initializing the root device, and providing functions to interact with USB devices such as resetting endpoints, clearing halts, and detaching kernel drivers. The code also handles errors and provides debugging information.

323 struct dirent *entry;

324

325 dir = opendir(usb_path);

326 if (!dir)

327 USB_ERROR_STR(-errno, "couldn't opendir(%s): %s", usb_path,

373 snprintf(dirpath, PATH_MAX, "%s/%s", usb_path, bus->dirname);

374

375 dir = opendir(dirpath);

376 if (!dir)

377 USB_ERROR_STR(-errno, "couldn't opendir(%s): %s", dirpath,

614 int found = 0;

615

616 dir = opendir(dirname);

617 if (!dir)

618 return 0;

index-15.html (https://jedit.svn.sourceforge.net/svnroot/jedit) HTML · 295 lines ✨ Summary

This HTML code is a navigation bar for a documentation website. It displays links to previous and next letters, as well as frames and no frames options. Below the navigation bar, there are links to various pages such as an overview, all classes, and help documentation. The page also includes a table of contents and a copyright notice at the bottom.

171 Method in class org.gjt.sp.jedit.proto.jeditresource.<A HREF="../org/gjt/sp/jedit/proto/jeditresource/Handler.html" title="class in org.gjt.sp.jedit.proto.jeditresource">Handler</A>

172 <DD>&nbsp;

173 <DT><A HREF="../org/gjt/sp/jedit/browser/FileCellRenderer.html#openDirIcon"><B>openDirIcon</B></A> -

174 Static variable in class org.gjt.sp.jedit.browser.<A HREF="../org/gjt/sp/jedit/browser/FileCellRenderer.html" title="class in org.gjt.sp.jedit.browser">FileCellRenderer</A>

175 <DD>&nbsp;

FileCellRenderer.java (https://jedit.svn.sourceforge.net/svnroot/jedit) Java · 291 lines ✨ Summary

This Java code defines a custom border component for a file browser, specifically designed to display directories and files in a tree-like structure. It includes icons for expansion and collapse, and adjusts its appearance based on the current state of the directory. The code is part of a larger application, likely a graphical user interface (GUI) for managing files and folders.

40 public static Icon openFileIcon = GUIUtilities.loadIcon("OpenFile.png");

41 public static Icon dirIcon = GUIUtilities.loadIcon("Folder.png");

42 public static Icon openDirIcon = GUIUtilities.loadIcon("OpenFolder.png");

43 public static Icon filesystemIcon = GUIUtilities.loadIcon("DriveSmall.png");

44 public static Icon loadingIcon = GUIUtilities.loadIcon("ReloadSmall.png");

171 {

172 if(file.getType() == VFSFile.DIRECTORY)

173 return (expanded ? openDirIcon : dirIcon);

174 else if(file.getType() == VFSFile.FILESYSTEM)

175 return filesystemIcon;

perlkw.swg (https://swig.svn.sourceforge.net/svnroot/swig) Unknown · 252 lines

131 PERLBN(mkdir);

132 PERLBN(open);

133 PERLBN(opendir);

134 PERLBN(readlink);

135 PERLBN(rename);

UIDocument.cc (https://freespeech.svn.sourceforge.net/svnroot/freespeech) C++ · 653 lines ✨ Summary

This C++ code is part of a neural network simulator, specifically a user interface (UIDocument) class that manages and runs simulations. It allows users to build, run, and visualize networks using a graphical interface. The code includes functions for building networks, running simulations, generating code, and updating network information.

421 struct stat my_stat;

422 string dirPath = basePath + "/" + path;

423 DIR *my_directory = opendir (dirPath.c_str());

424

425 if (!my_directory) return false;

FileCellRenderer.java (https://jedit.svn.sourceforge.net/svnroot/jedit) Java · 292 lines ✨ Summary

This Java code is part of a file explorer component, specifically designed to display directories and files in a graphical user interface. It handles icons, text rendering, and layout for directory entries, including toggle buttons for expanding/collapsing subdirectories. The code uses a custom border component to visually indicate the state of each entry.

44 public static Icon openFileIcon = GUIUtilities.loadIcon(jEdit.getProperty("vfs.browser.open-file.icon"));

45 public static Icon dirIcon = GUIUtilities.loadIcon(jEdit.getProperty("vfs.browser.dir.icon"));

46 public static Icon openDirIcon = GUIUtilities.loadIcon(jEdit.getProperty("vfs.browser.open-dir.icon"));

47 public static Icon filesystemIcon = GUIUtilities.loadIcon(jEdit.getProperty("vfs.browser.filesystem.icon"));

48 public static Icon loadingIcon = GUIUtilities.loadIcon(jEdit.getProperty("vfs.browser.loading.icon"));

file.c (http://omnia2droid.googlecode.com/svn/trunk/) C · 2029 lines ✨ Summary

This C code implements a file system for a networked storage device, specifically designed to work with the Linux kernel. It provides functions for reading and writing data from the device, handling file operations such as locking and unlocking, and notifying clients of changes. The code is part of the Fuse (Filesystem in Userspace) project, which allows userspace applications to access remote filesystems.

108 struct fuse_file *ff;

109 int err;

110 int opcode = isdir ? FUSE_OPENDIR : FUSE_OPEN;

111

112 ff = fuse_file_alloc(fc);