|
by: Fred Pacquier |
last post by:
First off, sorry for this message-in-a-bottle-like post... I haven't been
able to phrase my questions well enough to get a meaningful answer from
Google in my research. OTOH, it is standard flattery (but true) that this
group has a bunch of the nicest and most knowledgeable Usenet people
around, and I know for a fact that there are some pretty good spam-
related tools written in Python, so I thought I might get away with it
:-)
Yes,...
|
by: fuzzylollipop |
last post by:
I am trying to get the number of bytes used by files in a directory.
I am using a large directory ( lots of stuff checked out of multiple
large cvs repositories ) and there is lots of wasted time doing
multiple os.stat() on dirs and files from different methods.
|
by: Steven T. Hatton |
last post by:
I found the following two statements in the file linked below:
struct stat st;
stat(fileName.c_str(), &st);
http://websvn.kde.org/branches/work/kdevelop4-parser/main.cpp?rev=420247&view=markup
This is from /usr/include/sys/stat.h which I'm pretty sure is what #include
<sys/stat.h> is pulling in. I plain and simply do not understand what the
above two lines of code do. Can someone please explain?
|
by: David Farning |
last post by:
I am new to c and not yet sure of the boundary between c and it's
implementations. So please redirect me if this should be asked elsewhere.
I am working on a function to determine if a directory exists. The idea
comes from a snippet I found in a samba source file.
bool dirExist(char *dname)
{
struct stat *stbuf;
//stbuf = (struct stat*)malloc(sizeof(struct stat));
|
by: diadia |
last post by:
#include <sys/types.h>
#include <sys/stat.h>
#include "ctype.h"
#include <stdio.h>
int estimateLen(struct stat buf, FILE *fp)
{
size_t _size = buf.st_size / 4;
|
|
by: David Bear |
last post by:
I'm trying to use os.chmod and am refered to the stat module.
Is there are explanation of:
* S_ISUID
* S_ISGID
* S_ENFMT
* S_ISVTX
* S_IREAD
* S_IWRITE
* S_IEXEC
|
by: Michael Glassford |
last post by:
The Python 2.5 News at
http://www.python.org/download/releases/2.5/NEWS.txt states that Python
2.5 was changed to "Use Win32 API to implement os.stat/fstat. As a
result, subsecond timestamps are reported, the limit on path name
lengths is removed, and stat reports WindowsError now (instead of OSError)."
Although not mentioned in the Python 2.5 News, apparently there was a
similar change on Mac that I'm having some problems with. On the...
|
by: Joe Salmeri |
last post by:
I just upgraded from Python 2.4.2 to Python 2.5.1 and have found some
unexpected behavior that appears to be a bug in the os.stat module.
My OS is Windows XP SP2 + all updates.
I have several programs that have worked flawlessly on all previous Python
versions for years and they are now producing incorrect results in the code
that uses os.stat.
Searching through the 2.5.1 release notes I found the following:
|
by: Deniz Dogan |
last post by:
Hello.
I have a question regarding the st_mode field of the "stat" struct in
sys/stat.h. I'd like to know how to use the S_IRWXU, S_IRWXG and
S_IRWXO flags to mask the mode_t value into human readable form such
as 755, 644, etc. Currently I do something similar to this:
usr_t = (mod & S_IRWXU);
usr_r = (mod & S_IRUSR);
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|
|
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
|